Re: linux-next: build failure after merge of the driver-core tree

From: Greg KH
Date: Mon Nov 28 2022 - 06:50:21 EST


On Mon, Nov 28, 2022 at 01:36:00PM +1100, Stephen Rothwell wrote:
> Hi all,
>
> After merging the driver-core tree, today's linux-next build (powerpc
> ppc64_defconfig) failed like this:
>
> arch/powerpc/platforms/book3s/vas-api.c: In function 'vas_register_coproc_api':
> arch/powerpc/platforms/book3s/vas-api.c:590:38: error: assignment to 'char * (*)(const struct device *, umode_t *)' {aka 'char * (*)(const struct device *, short unsigned int *)'} from incompatible pointer type 'char * (*)(struct device *, umode_t *)' {aka 'char * (*)(struct device *, short unsigned int *)'} [-Werror=incompatible-pointer-types]
> 590 | coproc_device.class->devnode = coproc_devnode;
> | ^
> drivers/misc/cxl/file.c: In function 'cxl_file_init':
> drivers/misc/cxl/file.c:687:28: error: assignment to 'char * (*)(const struct device *, umode_t *)' {aka 'char * (*)(const struct device *, short unsigned int *)'} from incompatible pointer type 'char * (*)(struct device *, umode_t *)' {aka 'char * (*)(struct device *, short unsigned int *)'} [-Werror=incompatible-pointer-types]
> 687 | cxl_class->devnode = cxl_devnode;
> | ^
>
> Caused by commit
>
> ff62b8e6588f ("driver core: make struct class.devnode() take a const *")
>
> I have used the driver-core tree from next-20221125 for today.

Hm, how do we resolve problems like this where an api changes in my
branch but needs to be updated in another branch that is not in Linus's
tree yet?

Want me to make a patch for this for you to apply after the driver-core
merge?

thanks,

greg k-h