Skip to content

Commit

Permalink
backport: media: ipu6: fix compilation with kernels >= 6.11
Browse files Browse the repository at this point in the history
Accommodate to v6.11-rc1 commit d69d804845985 ("driver core: have match()
callback in struct bus_type take a const *").

Bug-Ubuntu: https://bugs.launchpad.net/bugs/2076262
Signed-off-by: You-Sheng Yang <[email protected]>
  • Loading branch information
vicamo committed Oct 15, 2024
1 parent 118952d commit 1e25f1e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/media/pci/intel/ipu-bus.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,13 @@ static const struct dev_pm_ops ipu_bus_pm_ops = {
#define IPU_BUS_PM_OPS NULL
#endif

#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 11, 0)
static int ipu_bus_match(struct device *dev, struct device_driver *drv)
#else
static int ipu_bus_match(struct device *dev, const struct device_driver *drv)
#endif
{
struct ipu_bus_driver *adrv = to_ipu_bus_driver(drv);
const struct ipu_bus_driver *adrv = to_ipu_bus_driver(drv);

dev_dbg(dev, "bus match: \"%s\" --- \"%s\"\n", dev_name(dev),
adrv->wanted);
Expand Down

0 comments on commit 1e25f1e

Please sign in to comment.