From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kay Sievers Date: Sun, 06 Jun 2004 23:37:19 +0000 Subject: Re: udev zombies Message-Id: <20040606233719.GA16551@vrfy.org> MIME-Version: 1 Content-Type: multipart/mixed; boundary="r5Pyd7+fXNt84Ff3" List-Id: References: <200406011914.13245.mbuesch@freenet.de> In-Reply-To: <200406011914.13245.mbuesch@freenet.de> To: linux-hotplug@vger.kernel.org --r5Pyd7+fXNt84Ff3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, Jun 06, 2004 at 03:38:52PM +0200, Michael Buesch wrote: > On Sunday 06 June 2004 15:16, you wrote: > > It would be great, if you are able to test it another time with the reenabled > > regparms. > > The attached patch fixes the whole stuff for me. > I imported some macros from the kernel. Ok, or do > you prefer other macro-names? > +#define asmlinkage __attribute__((regparm(0))) > +#define FASTCALL(x) x __attribute__((regparm(3))) > +#define fastcall __attribute__((regparm(3))) Hmm, I prefer no macro at all. Greg, here is the usual bk text: === fix udevd zombies The recent version of klibc switched to -mregparm=3. This broke the signal handlers parameter, cause it is called directly from the kernel with the parameter on the stack not in a register. === thanks, Kay --r5Pyd7+fXNt84Ff3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="01-udev-regparm-fix.patch" ===== udev.c 1.56 vs edited ===== --- 1.56/udev.c Thu Mar 25 00:21:41 2004 +++ edited/udev.c Mon Jun 7 00:49:17 2004 @@ -55,7 +55,7 @@ } #endif -static void sig_handler(int signum) +__attribute__((regparm(0))) static void sig_handler(int signum) { switch (signum) { case SIGINT: @@ -63,7 +63,7 @@ udevdb_exit(); exit(20 + signum); default: - dbg("unhandled signal"); + dbg("unhandled signal %d", signum); } } @@ -128,7 +128,7 @@ goto exit; } - /* set up a default signal handler for now */ + /* set signal handlers */ act.sa_handler = sig_handler; sigemptyset (&act.sa_mask); act.sa_flags = SA_RESTART; ===== udevd.c 1.32 vs edited ===== --- 1.32/udevd.c Fri May 21 06:13:45 2004 +++ edited/udevd.c Mon Jun 7 00:50:03 2004 @@ -306,9 +306,10 @@ return; } -static void sig_handler(int signum) +__attribute__((regparm(0))) static void sig_handler(int signum) { int rc; + switch (signum) { case SIGINT: case SIGTERM: @@ -325,7 +326,7 @@ goto do_write; break; default: - dbg("unhandled signal"); + dbg("unhandled signal %d", signum); return; } --r5Pyd7+fXNt84Ff3-- ------------------------------------------------------- This SF.Net email is sponsored by the new InstallShield X. >From Windows to Linux, servers to mobile, InstallShield X is the one installation-authoring solution that does it all. Learn more and evaluate today! http://www.installshield.com/Dev2Dev/0504 _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel