[kernel] r8314 - in dists/sid/linux-2.6/debian: . patches/bugfix/sparc patches/series

Jurij Smakov jurij-guest at alioth.debian.org
Tue Feb 20 04:14:10 UTC 2007


Author: jurij-guest
Date: Tue Feb 20 05:14:09 2007
New Revision: 8314

Added:
   dists/sid/linux-2.6/debian/patches/bugfix/sparc/sbus-envctrl-remove-execve.patch
Modified:
   dists/sid/linux-2.6/debian/changelog
   dists/sid/linux-2.6/debian/patches/series/11
Log:
Add sbus-envctrl-remove-execve.patch which is a backport of changes
to SBUS envctrl drivers from 2.6.19, making them use
call_usermodehelper() instead of execve() to call userspace 
programs. Fixes the failure of said drivers to load due to missing 
execve symbol. Confirmed working by Dann Frazier.


Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog	(original)
+++ dists/sid/linux-2.6/debian/changelog	Tue Feb 20 05:14:09 2007
@@ -6,6 +6,11 @@
     afford a global ABI bump at that point, so some out-of-tree modules
     in Sid may not load on sparc32 before the corresponding packages
     are rebuilt. Sorry for the inconvenience. (closes: #410497)
+  * Add sbus-envctrl-remove-execve.patch which is a backport of changes
+    to SBUS envctrl drivers from 2.6.19, making them use
+    call_usermodehelper() instead of execve() to call userspace programs.
+    Fixes the failure of said drivers to load due to missing execve
+    symbol. Thanks to Dann Frazier for testing. (closes: #411135)
 
   [ dann frazier ]
   * atiixp: fix bug that restricts controller to a single channel.

Added: dists/sid/linux-2.6/debian/patches/bugfix/sparc/sbus-envctrl-remove-execve.patch
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/sparc/sbus-envctrl-remove-execve.patch	Tue Feb 20 05:14:09 2007
@@ -0,0 +1,66 @@
+diff -aur a/drivers/sbus/char/bbc_envctrl.c b/drivers/sbus/char/bbc_envctrl.c
+--- a/drivers/sbus/char/bbc_envctrl.c	2006-09-19 20:42:06.000000000 -0700
++++ b/drivers/sbus/char/bbc_envctrl.c	2007-02-18 09:51:07.000000000 -0800
+@@ -4,14 +4,12 @@
+  * Copyright (C) 2001 David S. Miller (davem at redhat.com)
+  */
+ 
+-#define __KERNEL_SYSCALLS__
+-static int errno;
+-
+ #include <linux/kernel.h>
+ #include <linux/kthread.h>
+ #include <linux/sched.h>
+ #include <linux/slab.h>
+ #include <linux/delay.h>
++#include <linux/kmod.h>
+ #include <asm/oplib.h>
+ #include <asm/ebus.h>
+ 
+@@ -200,7 +198,7 @@
+ 	printk(KERN_CRIT "kenvctrld: Shutting down the system now.\n");
+ 
+ 	shutting_down = 1;
+-	if (execve("/sbin/shutdown", argv, envp) < 0)
++	if (call_usermodehelper("/sbin/shutdown", argv, envp, 0) < 0)
+ 		printk(KERN_CRIT "envctrl: shutdown execution failed\n");
+ }
+ 
+diff -aur a/drivers/sbus/char/envctrl.c b/drivers/sbus/char/envctrl.c
+--- a/drivers/sbus/char/envctrl.c	2006-09-19 20:42:06.000000000 -0700
++++ b/drivers/sbus/char/envctrl.c	2007-02-18 09:55:05.000000000 -0800
+@@ -19,9 +19,6 @@
+  *              Daniele Bellucci <bellucda at tiscali.it>
+  */
+ 
+-#define __KERNEL_SYSCALLS__
+-static int errno;
+-
+ #include <linux/module.h>
+ #include <linux/sched.h>
+ #include <linux/kthread.h>
+@@ -33,6 +30,7 @@
+ #include <linux/mm.h>
+ #include <linux/slab.h>
+ #include <linux/kernel.h>
++#include <linux/kmod.h>
+ 
+ #include <asm/ebus.h>
+ #include <asm/uaccess.h>
+@@ -976,13 +974,15 @@
+ 		"HOME=/", "TERM=linux", "PATH=/sbin:/usr/sbin:/bin:/usr/bin", NULL };
+ 	char *argv[] = { 
+ 		"/sbin/shutdown", "-h", "now", NULL };	
++	int ret;
+ 
+ 	if (inprog != 0)
+ 		return;
+ 
+ 	inprog = 1;
+ 	printk(KERN_CRIT "kenvctrld: WARNING: Shutting down the system now.\n");
+-	if (0 > execve("/sbin/shutdown", argv, envp)) {
++	ret = call_usermodehelper("/sbin/shutdown", argv, envp, 0);
++	if (ret < 0) {
+ 		printk(KERN_CRIT "kenvctrld: WARNING: system shutdown failed!\n"); 
+ 		inprog = 0;  /* unlikely to succeed, but we could try again */
+ 	}

Modified: dists/sid/linux-2.6/debian/patches/series/11
==============================================================================
--- dists/sid/linux-2.6/debian/patches/series/11	(original)
+++ dists/sid/linux-2.6/debian/patches/series/11	Tue Feb 20 05:14:09 2007
@@ -4,3 +4,4 @@
 + bugfix/uml-compilation.patch
 + bugfix/net-ipx-annotation-checksum.patch
 + bugfix/ib-mad-fix-race-between-cancel-and-receive-completion.patch
++ bugfix/sparc/sbus-envctrl-remove-execve.patch



More information about the Kernel-svn-changes mailing list