On 22.08.2024 18:38:59, Martin Jocic wrote: > Use the IS_ENABLED() macro to check kernel config defines > instead of #ifdef. > > Signed-off-by: Martin Jocic <martin.jocic@xxxxxxxxxx> On platforms with CONFIG_ARCH_DMA_ADDR_T_64BIT not set this throws the following warning: | drivers/net/can/kvaser_pciefd.c: In function ‘kvaser_pciefd_write_dma_map_altera’: | drivers/net/can/kvaser_pciefd.c:1058:30: error: right shift count >= width of type [-Werror=shift-count-overflow] | 1058 | word2 = addr >> 32; | | ^~ I'm using upper_32_bits() to avoid this warning. https://elixir.bootlin.com/linux/v6.10.6/source/include/linux/wordpart.h#L14 regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung Nürnberg | Phone: +49-5121-206917-129 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-9 |
Attachment:
signature.asc
Description: PGP signature