Skip to contentSkip to conversation

fix sti-netlink.c compilation failure

PATCH In review Paul Walmsley 3 participants 3 messages May 8, 2007 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH 1/1 fix sti-netlink.c compilation failure

Fix this compilation error in current linux-omap-2.6 git head:

CC arch/arm/plat-omap/sti/sti-netlink.o
arch/arm/plat-omap/sti/sti-netlink.c: In function 'sti_netlink_init':
arch/arm/plat-omap/sti/sti-netlink.c:145: warning: passing argument 4 of 'netlink_kernel_create' from incompatible pointer type arch/arm/plat-omap/sti/sti-netlink.c:145: error: too few arguments to function 'netlink_kernel_create' make[2]: *** [arch/arm/plat-omap/sti/sti-netlink.o] Error 1
make[1]: *** [arch/arm/plat-omap/sti] Error 2
make: *** [arch/arm/plat-omap] Error 2

Compile-tested only.

---
 arch/arm/plat-omap/sti/sti-netlink.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm/plat-omap/sti/sti-netlink.c +2 -1
Index: linux-omap-2.6/arch/arm/plat-omap/sti/sti-netlink.c
===================================================================
@@ -142,7 +142,8 @@ static void sti_netlink_receive(struct s
 static int __init sti_netlink_init(void)
 {
 	sti_sock = netlink_kernel_create(NETLINK_USERSOCK, 0,
-					 sti_netlink_receive, THIS_MODULE);
+					 sti_netlink_receive, NULL,
+					 THIS_MODULE);
 	if (!sti_sock) {
 		printk(KERN_ERR "STI: Failed to create netlink socket\n");
 		return -ENODEV;
#2 lore raw
Quoted 24 lines · Paul Walmsley

Fix this compilation error in current linux-omap-2.6 git head:

CC arch/arm/plat-omap/sti/sti-netlink.o
arch/arm/plat-omap/sti/sti-netlink.c: In function 'sti_netlink_init':
arch/arm/plat-omap/sti/sti-netlink.c:145: warning: passing argument 4 of 'netlink_kernel_create' from incompatible pointer type arch/arm/plat-omap/sti/sti-netlink.c:145: error: too few arguments to function 'netlink_kernel_create' make[2]: *** [arch/arm/plat-omap/sti/sti-netlink.o] Error 1
make[1]: *** [arch/arm/plat-omap/sti] Error 2
make: *** [arch/arm/plat-omap] Error 2

Compile-tested only.

---
 arch/arm/plat-omap/sti/sti-netlink.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Index: linux-omap-2.6/arch/arm/plat-omap/sti/sti-netlink.c
===================================================================

arch/arm/plat-omap/sti/sti-netlink.c static void sti_netlink_receive(struct s · line 149

Quoted 9 lines
arch/arm/plat-omap/sti/sti-netlink.c +2 -1
@@ -142,7 +142,8 @@ static void sti_netlink_receive(struct s
 static int __init sti_netlink_init(void)
 {
 	sti_sock = netlink_kernel_create(NETLINK_USERSOCK, 0,
-					 sti_netlink_receive, THIS_MODULE);
+					 sti_netlink_receive, NULL,
+					 THIS_MODULE);
 	if (!sti_sock) {
 		printk(KERN_ERR "STI: Failed to create netlink socket\n");
 		return -ENODEV;

Thanks, pushing today.

Tony

Acked-by on v1 1/1
#3 lore raw
In reply to Paul Walmsley
Quoted 10 lines · Paul Walmsley

Fix this compilation error in current linux-omap-2.6 git head:

CC arch/arm/plat-omap/sti/sti-netlink.o
arch/arm/plat-omap/sti/sti-netlink.c: In function 'sti_netlink_init':
arch/arm/plat-omap/sti/sti-netlink.c:145: warning: passing argument 4 of 'netlink_kernel_create' from incompatible pointer type arch/arm/plat-omap/sti/sti-netlink.c:145: error: too few arguments to function 'netlink_kernel_create' make[2]: *** [arch/arm/plat-omap/sti/sti-netlink.o] Error 1
make[1]: *** [arch/arm/plat-omap/sti] Error 2
make: *** [arch/arm/plat-omap] Error 2

Quoted 4 lines

Compile-tested only.

Looks reasonable.