mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 09:11:26 +03:00
media: virtual-i2c-mux: Fix build for Linux v6.10
In Linux v6.10, the 'class' argument was removed from the i2c_mux_add_adapter() function. Add a test to conftest to detect the correct number of arguments for i2c_mux_add_adapter() and update the virtual-i2c-mux driver accordingly to fix the build for Linux v6.10. Bug 4593750 Change-Id: I7333a511b487b7c2f2fa0ce7c34f2df5f061fbe4 Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3142398 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
1b72d87cce
commit
5e0562c90d
@@ -5451,6 +5451,23 @@ compile_test() {
|
||||
compile_check_conftest "$CODE" "NV_I2C_DRIVER_STRUCT_REMOVE_RETURN_TYPE_INT" "" "types"
|
||||
;;
|
||||
|
||||
i2c_mux_add_adapter_has_no_class_argument)
|
||||
#
|
||||
# Determine if the i2c_mux_add_adapter() has no class argument.
|
||||
#
|
||||
# Commit fec1982d7072 ("i2c: mux: Remove class argument from i2c_mux_add_adapter()")
|
||||
# removed the 'class' argument from i2c_mux_add_adapter() in Linux v6.10.
|
||||
#
|
||||
CODE="
|
||||
#define _LINUX_EFI_H
|
||||
#include <linux/i2c-mux.h>
|
||||
int conftest_i2c_mux_add_adapter_has_no_class_argument(struct i2c_mux_core *muxc) {
|
||||
return i2c_mux_add_adapter(muxc, 0, 0);
|
||||
}"
|
||||
|
||||
compile_check_conftest "$CODE" "NV_I2C_MUX_ADD_ADAPTER_HAS_NO_CLASS_ARG" "" "types"
|
||||
;;
|
||||
|
||||
of_get_named_gpio)
|
||||
#
|
||||
# Determine if of_get_named_gpio() function is present
|
||||
|
||||
Reference in New Issue
Block a user