mcb: mcb patch for v6.20
cover mcb: mcb patch for v6.20
From: Johannes Thumshirn <[email protected]>
Hi Greg,
Here's a patch from Javier for mcb removing an obsolete sanity check which ultimately caused the mcb attached gpio driver to fail loading.
Please consider this submission for 6.20
Jose Javier Rodriguez Barbarin (1):
mcb: fix incorrect sanity check
drivers/mcb/mcb-core.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
Signature · 1 line
2.51.0
PATCH 1/1 mcb: fix incorrect sanity check
From: Jose Javier Rodriguez Barbarin <[email protected]>
__mcb_register_driver() makes some sanity checks over mcb_driver to check if .probe and .remove callbacks are set. However, since commit 3bd13ae04ccc ("gpio: menz127: simplify error path and remove remove()") removed the .remove callback from menz127-gpio.c, not all mcb device drivers implement .remove callback.
Remove .remove check to ensure all mcb device drivers can be loaded.
--- drivers/mcb/mcb-core.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
drivers/mcb/mcb-core.c +5 -4
@@ -85,7 +85,8 @@ static void mcb_remove(struct device *dev)struct mcb_device *mdev =to_mcb_device (dev);struct module *carrier_mod; - mdrv->remove (mdev); +if (mdrv->remove) + mdrv->remove (mdev); carrier_mod = mdev->dev.parent->driver->owner;module_put (carrier_mod);
@@ -176,13 +177,13 @@ static const struct device_type mcb_carrier_device_type = {* @owner: The @mcb_driver's module * @mod_name: The name of the @mcb_driver's module * -* Register a @mcb_driver at the system. Perform some sanity checks, if -* the .probe and .remove methods are provided by the driver. +* Register a @mcb_driver at the system. Perform a sanity check, if +* .probe method is provided by the driver. */ int __mcb_register_driver (struct mcb_driver *drv,struct module *owner,const char *mod_name) { -if (!drv->probe || !drv->remove) +if (!drv->probe)return -EINVAL ; drv->driver.owner = owner;
Signature · 1 line
2.51.0
Johannes Thumshirn
maintainerQuoted 7 lines · Johannes Thumshirn
From: Johannes Thumshirn <[email protected]>
Hi Greg,
Here's a patch from Javier for mcb removing an obsolete sanity check which ultimately caused the mcb attached gpio driver to fail loading.
Quoted 8 lines
Please consider this submission for 6.20
Jose Javier Rodriguez Barbarin (1):
mcb: fix incorrect sanity checkdrivers/mcb/mcb-core.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)
Sorry Greg,
I messed up my mail setup again.
Quoted 13 lines · Johannes Thumshirn
Quoted 12 lines · Johannes Thumshirn
From: Johannes Thumshirn <[email protected]>
Hi Greg,
Here's a patch from Javier for mcb removing an obsolete sanity check which ultimately caused the mcb attached gpio driver to fail loading.
Please consider this submission for 6.20
Jose Javier Rodriguez Barbarin (1):
mcb: fix incorrect sanity check
Quoted 6 lines
Quoted 3 lines
drivers/mcb/mcb-core.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-)Sorry Greg,
I messed up my mail setup again.
Can you please resend this, I don't see it anywhere :(