mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 17:25:35 +03:00
conftest: Add test to find if struct gpio_chip has of_node
Determine if struct gpio_chip has the of_node member or not.
The of_node from struct gpio_chip is removed from
commit 70d0fc4288dab ("gpiolib: Get rid of not
used of_node member") in Linux 6.2
Bug 4346767
Change-Id: I5ebc86beb7ce527f2e38693dd59907cdd3a8fcf9
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3031548
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
5f188c61f5
commit
05cf355367
@@ -5496,6 +5496,24 @@ compile_test() {
|
||||
compile_check_conftest "$CODE" "NV_OF_GPIO_NAMED_COUNT_PRESENT" "" "functions"
|
||||
;;
|
||||
|
||||
gpio_chip_struct_has_of_node_present)
|
||||
#
|
||||
# Determine if struct gpio_chip has the of_node member or not.
|
||||
#
|
||||
# The of_node from struct gpio_chip is removed from commit 70d0fc4288dab
|
||||
# ("gpiolib: Get rid of not used of_node member") in Linux 6.2
|
||||
#
|
||||
CODE="
|
||||
#include <linux/gpio/driver.h>
|
||||
int conftest_gpio_chip_struct_has_of_node_present(void)
|
||||
{
|
||||
return offsetof(struct gpio_chip, of_node);
|
||||
}
|
||||
"
|
||||
|
||||
compile_check_conftest "$CODE" "NV_GPIO_CHIP_STRUCT_HAS_OF_NODE_PRESENT" "" "types"
|
||||
;;
|
||||
|
||||
devm_gpio_request_one)
|
||||
#
|
||||
# Determine if devm_gpio_request_one() function is present
|
||||
|
||||
Reference in New Issue
Block a user