Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: fsl-mc: bus: Drop warning

When updating the irq_chip and msi_domain_ops, the code checkes for
already present functions.
When more then one ITS controller are present in the system,
irq_chip and msi_domain_ops got already set and a warning is invoked.

This patch deletes the warning, as the funtions are just already set to
the needed callbacks.

Signed-off-by: Matthias Brugger <mbrugger@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Matthias Brugger and committed by
Greg Kroah-Hartman
33ea58a9 63344050

+4 -8
+4 -8
drivers/staging/fsl-mc/bus/mc-msi.c
··· 37 37 /* 38 38 * set_desc should not be set by the caller 39 39 */ 40 - if (WARN_ON(ops->set_desc)) 41 - return; 42 - 43 - ops->set_desc = fsl_mc_msi_set_desc; 40 + if (ops->set_desc == NULL) 41 + ops->set_desc = fsl_mc_msi_set_desc; 44 42 } 45 43 46 44 static void __fsl_mc_msi_write_msg(struct fsl_mc_device *mc_bus_dev, ··· 127 129 /* 128 130 * irq_write_msi_msg should not be set by the caller 129 131 */ 130 - if (WARN_ON(chip->irq_write_msi_msg)) 131 - return; 132 - 133 - chip->irq_write_msi_msg = fsl_mc_msi_write_msg; 132 + if (chip->irq_write_msi_msg == NULL) 133 + chip->irq_write_msi_msg = fsl_mc_msi_write_msg; 134 134 } 135 135 136 136 /**