diff options
author | Alexander Shishkin <alexander.shishkin@linux.intel.com> | 2016-11-18 14:36:39 +0100 |
---|---|---|
committer | Alexander Shishkin <alexander.shishkin@linux.intel.com> | 2017-08-25 16:58:37 +0200 |
commit | 8edc514b01e9cfbc037c708e5260f248cbb4d867 (patch) | |
tree | e40e437d8f6bd090cdb36a821a03fb98fe236df4 /drivers/hwtracing/intel_th/core.c | |
parent | intel_th: Streamline the subdevice tree accessors (diff) | |
download | linux-8edc514b01e9cfbc037c708e5260f248cbb4d867.tar.xz linux-8edc514b01e9cfbc037c708e5260f248cbb4d867.zip |
intel_th: Make SOURCE devices children of the root device
The switch (GTH) does not directly interact with SOURCE type devices and
may not even be present (in host mode). To reflect this and avoid
inconsistencies between target and host mode, make SOURCE devices
descendant directly from the root (i.e. PCI) device. Their symlinks
will no longer appear under the switch device, but they can still
be found under intel_th bus.
Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Diffstat (limited to 'drivers/hwtracing/intel_th/core.c')
-rw-r--r-- | drivers/hwtracing/intel_th/core.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/hwtracing/intel_th/core.c b/drivers/hwtracing/intel_th/core.c index e6d302ba1707..323d3ac8d4f7 100644 --- a/drivers/hwtracing/intel_th/core.c +++ b/drivers/hwtracing/intel_th/core.c @@ -311,10 +311,10 @@ intel_th_device_alloc(struct intel_th *th, unsigned int type, const char *name, struct device *parent; struct intel_th_device *thdev; - if (type == INTEL_TH_SWITCH) - parent = th->dev; - else + if (type == INTEL_TH_OUTPUT) parent = &th->hub->dev; + else + parent = th->dev; thdev = kzalloc(sizeof(*thdev) + strlen(name) + 1, GFP_KERNEL); if (!thdev) |