mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 09:11:26 +03:00
net: can: mttcan: Fix build for Linux v6.16
In Linux v6.16, the structure 'data_bittiming_params' was added to the 'can_priv' structure and all the related data bittiming parameters were moved under this new structure. Add a test to conftest to determine if this new structure is present and update the Tegra MTTCAN driver accordingly. JIRA LINQPJ14-60 Change-Id: Ibd8f6bd81a903b15a55d837023dada835a1e72ca Signed-off-by: Jon Hunter <jonathanh@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3374645 (cherry picked from commit 86396ec47b78a7716a5faa8d492d74efc7f23dce) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3461874 Reviewed-by: Brad Griffis <bgriffis@nvidia.com> GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
96cae7f9de
commit
594c03645c
@@ -106,6 +106,7 @@ NV_CONFTEST_FUNCTION_COMPILE_TESTS += blk_mq_f_should_merge
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += bus_type_struct_match_has_const_drv_arg
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += bus_type_struct_remove_has_int_return_type
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += bus_type_struct_uevent_has_const_dev_arg
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += can_priv_struct_has_struct_data_bittiming_params
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += class_attribute_struct_has_const_struct_class_attribute
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += class_create_has_no_owner_arg
|
||||
NV_CONFTEST_FUNCTION_COMPILE_TESTS += class_struct_devnode_has_const_dev_arg
|
||||
|
||||
@@ -6832,6 +6832,24 @@ compile_test() {
|
||||
compile_check_conftest "$CODE" "NV_BUS_TYPE_STRUCT_UEVENT_HAS_CONST_DEV_ARG" "" "types"
|
||||
;;
|
||||
|
||||
can_priv_struct_has_struct_data_bittiming_params)
|
||||
#
|
||||
# Determine if the 'can_priv' structure has a member of type
|
||||
# 'structure data_bittiming_params'.
|
||||
#
|
||||
# In Linux v6.16, commit b803c4a4f788 ("can: dev: add struct
|
||||
# data_bittiming_params to group FD parameters") added the
|
||||
# 'data_bittiming_params' structure to the 'can_priv' structure.
|
||||
#
|
||||
CODE="
|
||||
#include <linux/can/dev.h>
|
||||
int conftest_can_priv_struct_has_struct_data_bittiming_params(void) {
|
||||
return offsetof(struct can_priv, fd);
|
||||
}"
|
||||
|
||||
compile_check_conftest "$CODE" "NV_CAN_PRIV_STRUCT_HAS_STRUCT_DATA_BITTIMING_PARAMS" "" "types"
|
||||
;;
|
||||
|
||||
class_attribute_struct_has_const_struct_class_attribute)
|
||||
#
|
||||
# Determine if struct class_attribute function has const type "struct class_attribute"
|
||||
|
||||
Reference in New Issue
Block a user