lkml.org 
[lkml]   [2005]   [May]   [31]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
DateTue, 31 May 2005 08:26:27 +0200
FromGuillaume Thouvenin <>
Subject[PATCH 2.6.12-rc5-mm1] fork connector: fix a compile breakage with gcc 2.95
Hello,

  This patch fixes a compile breakage with gcc 2.95 due to an unnamed
struct/union that doesn't define any instances. Thank you to Adrian Bunk
for reporting the problem and testing the new patch.

Signed-off-by: guillaume.thouvenin@bull.net

---
 drivers/connector/cn_fork.c |   10 +++++-----
 include/linux/cn_fork.h     |    4 ++--
 2 files changed, 7 insertions(+), 7 deletions(-)
Index: linux-2.6.12-rc5-mm1/drivers/connector/cn_fork.c
===================================================================
--- linux-2.6.12-rc5-mm1.orig/drivers/connector/cn_fork.c	2005-05-30 09:05:43.000000000 +0200
+++ linux-2.6.12-rc5-mm1/drivers/connector/cn_fork.c	2005-05-30 13:02:36.000000000 +0200
@@ -72,10 +72,10 @@ void fork_connector(pid_t ppid, pid_t pt
 		forkmsg = (struct cn_fork_msg *)msg->data;
 		forkmsg->type = FORK_CN_MSG_P;
 		forkmsg->cpu = smp_processor_id();
-		forkmsg->ppid = ppid;
-		forkmsg->ptid = ptid;
-		forkmsg->cpid = cpid;
-		forkmsg->ctid = ctid;
+		forkmsg->u.s.ppid = ppid;
+		forkmsg->u.s.ptid = ptid;
+		forkmsg->u.s.cpid = cpid;
+		forkmsg->u.s.ctid = ctid;
 
 		put_cpu_var(fork_counts);
 
@@ -107,7 +107,7 @@ static inline void cn_fork_send_status(v
 	msg->len = CN_FORK_INFO_SIZE;
 	forkmsg = (struct cn_fork_msg *)msg->data;
 	forkmsg->type = FORK_CN_MSG_S;
-	forkmsg->status = cn_fork_enable;
+	forkmsg->u.status = cn_fork_enable;
 
 	cn_netlink_send(msg, CN_IDX_FORK, GFP_KERNEL);
 }
Index: linux-2.6.12-rc5-mm1/include/linux/cn_fork.h
===================================================================
--- linux-2.6.12-rc5-mm1.orig/include/linux/cn_fork.h	2005-05-30 09:05:51.000000000 +0200
+++ linux-2.6.12-rc5-mm1/include/linux/cn_fork.h	2005-05-30 13:07:26.000000000 +0200
@@ -55,9 +55,9 @@ struct cn_fork_msg {
 			pid_t ptid;	/* parent thread ID  */
 			pid_t cpid;	/* child process ID  */
 			pid_t ctid;	/* child thread ID   */
-		};
+		} s;
 		int status;
-	};
+	} u;
 };
 
 /* Code above is only inside the kernel */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-05-31 08:30    [from the cache]
©2003-2008