intel_th: Fix activating a subdevice without a driver
authorAlexander Shishkin <alexander.shishkin@linux.intel.com>
Mon, 7 Mar 2016 15:04:45 +0000 (17:04 +0200)
committerAlexander Shishkin <alexander.shishkin@linux.intel.com>
Fri, 8 Apr 2016 13:11:58 +0000 (16:11 +0300)
commitf18a9531f6da9aba2920a3a5f166dba5a20592a0
tree4e88611c1a4817d6d7a6dc81ef57e79527d18e08
parente8644e4c2aa5c52c357f63af9cc17ef5dce38396
intel_th: Fix activating a subdevice without a driver

If output subdevice driver is not loaded, activating it will try to
call its ->activate method and crash. Fix this by explicitly checking
for the driver.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Reviewed-by: Laurent Fert <laurent.fert@intel.com>
drivers/hwtracing/intel_th/core.c
drivers/hwtracing/intel_th/intel_th.h