diff options
Diffstat (limited to 'arch/powerpc/platforms/ps3/system-bus.c')
-rw-r--r-- | arch/powerpc/platforms/ps3/system-bus.c | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/platforms/ps3/system-bus.c index d66c3628a112..280ee88cb0b0 100644 --- a/arch/powerpc/platforms/ps3/system-bus.c +++ b/arch/powerpc/platforms/ps3/system-bus.c | |||
@@ -347,16 +347,23 @@ static int ps3_system_bus_match(struct device *_dev, | |||
347 | struct ps3_system_bus_driver *drv = ps3_drv_to_system_bus_drv(_drv); | 347 | struct ps3_system_bus_driver *drv = ps3_drv_to_system_bus_drv(_drv); |
348 | struct ps3_system_bus_device *dev = ps3_dev_to_system_bus_dev(_dev); | 348 | struct ps3_system_bus_device *dev = ps3_dev_to_system_bus_dev(_dev); |
349 | 349 | ||
350 | result = dev->match_id == drv->match_id; | 350 | if (!dev->match_sub_id) |
351 | result = dev->match_id == drv->match_id; | ||
352 | else | ||
353 | result = dev->match_sub_id == drv->match_sub_id && | ||
354 | dev->match_id == drv->match_id; | ||
351 | 355 | ||
352 | if (result) | 356 | if (result) |
353 | pr_info("%s:%d: dev=%u(%s), drv=%u(%s): match\n", __func__, | 357 | pr_info("%s:%d: dev=%u.%u(%s), drv=%u.%u(%s): match\n", |
354 | __LINE__, dev->match_id, dev->core.bus_id, | 358 | __func__, __LINE__, |
355 | drv->match_id, drv->core.name); | 359 | dev->match_id, dev->match_sub_id, dev->core.bus_id, |
360 | drv->match_id, drv->match_sub_id, drv->core.name); | ||
356 | else | 361 | else |
357 | pr_debug("%s:%d: dev=%u(%s), drv=%u(%s): miss\n", __func__, | 362 | pr_debug("%s:%d: dev=%u.%u(%s), drv=%u.%u(%s): miss\n", |
358 | __LINE__, dev->match_id, dev->core.bus_id, | 363 | __func__, __LINE__, |
359 | drv->match_id, drv->core.name); | 364 | dev->match_id, dev->match_sub_id, dev->core.bus_id, |
365 | drv->match_id, drv->match_sub_id, drv->core.name); | ||
366 | |||
360 | return result; | 367 | return result; |
361 | } | 368 | } |
362 | 369 | ||