rpms/kernel/devel kernel.spec, 1.624, 1.625 linux-2.6-utrace.patch, 1.75, 1.76

Roland McGrath (roland) fedora-extras-commits at redhat.com
Tue May 6 01:07:18 UTC 2008


Author: roland

Update of /cvs/pkgs/rpms/kernel/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv23238

Modified Files:
	kernel.spec linux-2.6-utrace.patch 
Log Message:
Fix testing of %%fedora macro.


Index: kernel.spec
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/kernel.spec,v
retrieving revision 1.624
retrieving revision 1.625
diff -u -r1.624 -r1.625
--- kernel.spec	3 May 2008 03:36:55 -0000	1.624
+++ kernel.spec	6 May 2008 01:06:40 -0000	1.625
@@ -473,7 +473,7 @@
 
 %define fancy_debuginfo 0
 %if %{with_debuginfo}
-%if "%fedora" > "7"
+%if 0%{?fedora} >= 8
 %define fancy_debuginfo 1
 %endif
 %endif
@@ -1799,6 +1799,9 @@
 %kernel_variant_files -a /%{image_install_path}/xen*-%{KVERREL}.xen -e /etc/ld.so.conf.d/kernelcap-%{KVERREL}.xen.conf %{with_xen} xen
 
 %changelog
+* Mon May  5 2008 Roland McGrath <roland at redhat.com> 2.6.25.1-2
+- Fix testing of %%fedora macro.
+
 * Fri May 02 2008 Jarod Wilson <jwilson at redhat.com> 2.6.25.1-1
 - Linux 2.6.25.1
 - Drop patches merged in 2.6.25.1:
@@ -1897,7 +1900,7 @@
 - update to latest nouveau drm from git
 
 * Sun Apr 13 2008 David Woodhouse <dwmw2 at redhat.com>
-- Remove 'CHRP' from /proc/cpuinfo on Efika, to fix platform detection 
+- Remove 'CHRP' from /proc/cpuinfo on Efika, to fix platform detection
   in anaconda
 
 * Sat Apr 12 2008 Jarod Wilson <jwilson at redhat.com>
@@ -2222,7 +2225,7 @@
 * Mon Mar 24 2008 Dave Jones <davej at redhat.com>
 - Add man pages for kernel API to kernel-doc package.
 
-* Mon Mar 24 2008 Jeremy Katz <katzj at redhat.com> 
+* Mon Mar 24 2008 Jeremy Katz <katzj at redhat.com>
 - Update the kvm patch to a more final one
 
 * Mon Mar 24 2008 Jarod Wilson <jwilson at redhat.com>

linux-2.6-utrace.patch:

View full diff with command:
/usr/bin/cvs -f diff  -kk -u -N -r 1.75 -r 1.76 linux-2.6-utrace.patch
Index: linux-2.6-utrace.patch
===================================================================
RCS file: /cvs/pkgs/rpms/kernel/devel/linux-2.6-utrace.patch,v
retrieving revision 1.75
retrieving revision 1.76
diff -u -r1.75 -r1.76
--- linux-2.6-utrace.patch	26 Mar 2008 00:03:08 -0000	1.75
+++ linux-2.6-utrace.patch	6 May 2008 01:06:40 -0000	1.76
@@ -1,64 +1,85 @@
  Documentation/DocBook/Makefile      |    2 +-
  Documentation/DocBook/utrace.tmpl   |   23 +
  Documentation/utrace.txt            |  579 +++++++++
+ arch/alpha/kernel/ptrace.c          |   15 +-
+ arch/arm/kernel/ptrace.c            |    5 +-
+ arch/avr32/kernel/ptrace.c          |    5 +-
+ arch/blackfin/kernel/ptrace.c       |    5 +-
+ arch/frv/kernel/ptrace.c            |    3 +-
+ arch/h8300/kernel/ptrace.c          |    3 +-
+ arch/ia64/kernel/process.c          |    2 +-
+ arch/ia64/kernel/ptrace.c           |   17 +-
+ arch/m32r/kernel/ptrace.c           |    7 +-
+ arch/m68k/kernel/ptrace.c           |    5 +-
+ arch/m68knommu/kernel/ptrace.c      |    3 +-
  arch/mips/kernel/irixelf.c          |    2 -
- arch/powerpc/kernel/asm-offsets.c   |    4 -
+ arch/mips/kernel/ptrace.c           |    5 +-
+ arch/mn10300/kernel/ptrace.c        |    3 +-
+ arch/parisc/kernel/ptrace.c         |    7 +-
+ arch/powerpc/kernel/entry_32.S      |    4 +-
  arch/powerpc/kernel/process.c       |    5 -
- arch/powerpc/kernel/ptrace.c        |   35 +-
- arch/powerpc/kernel/ptrace32.c      |    2 +-
- arch/powerpc/kernel/signal.c        |    8 +-
- arch/powerpc/kernel/signal_32.c     |   19 +-
+ arch/powerpc/kernel/ptrace.c        |   38 +-
+ arch/powerpc/kernel/ptrace32.c      |    8 +-
+ arch/powerpc/kernel/signal.c        |   20 +-
+ arch/powerpc/kernel/signal_32.c     |   21 +-
  arch/powerpc/kernel/sys_ppc32.c     |    5 -
+ arch/s390/kernel/entry.S            |   14 +-
+ arch/s390/kernel/entry64.S          |   12 +-
+ arch/sh/kernel/ptrace_32.c          |    5 +-
+ arch/sh/kernel/ptrace_64.c          |    5 +-
+ arch/sparc/kernel/ptrace.c          |    5 +-
  arch/sparc64/kernel/binfmt_aout32.c |    2 -
- arch/sparc64/kernel/process.c       |   23 +-
- arch/sparc64/kernel/ptrace.c        |   28 +-
- arch/sparc64/kernel/sys_sparc32.c   |   41 +-
+ arch/sparc64/kernel/ptrace.c        |   35 +-
+ arch/um/kernel/ptrace.c             |    3 +-
+ arch/v850/kernel/ptrace.c           |    3 +-
  arch/x86/ia32/ia32_aout.c           |    6 -
- arch/x86/ia32/ia32_signal.c         |   10 -
+ arch/x86/ia32/ia32_signal.c         |   12 +-
  arch/x86/ia32/ia32entry.S           |   14 +-
  arch/x86/ia32/sys_ia32.c            |    5 -
  arch/x86/kernel/entry_64.S          |    8 +-
- arch/x86/kernel/ptrace.c            |  157 +--
- arch/x86/kernel/signal_32.c         |   37 +-
- arch/x86/kernel/signal_64.c         |   33 +-
+ arch/x86/kernel/ptrace.c            |  159 +--
+ arch/x86/kernel/signal_32.c         |   56 +-
+ arch/x86/kernel/signal_64.c         |   49 +-
+ arch/x86/kernel/step.c              |   22 +-
  arch/x86/kernel/vm86_32.c           |    9 +-
+ arch/xtensa/kernel/ptrace.c         |    6 +-
  fs/binfmt_aout.c                    |    6 -
  fs/binfmt_elf.c                     |    6 -
  fs/binfmt_elf_fdpic.c               |    7 -
  fs/binfmt_flat.c                    |    3 -
  fs/binfmt_som.c                     |    2 -
- fs/compat.c                         |    6 +-
- fs/eventpoll.c                      |    3 +-
+ fs/compat.c                         |   14 +-
+ fs/eventpoll.c                      |    7 +-
  fs/exec.c                           |   12 +-
  fs/proc/array.c                     |    9 +-
  fs/proc/base.c                      |   43 +-
- fs/select.c                         |    4 +-
- include/asm-alpha/ptrace.h          |    1 +
- include/asm-ia64/ptrace.h           |    1 +
- include/asm-ia64/thread_info.h      |    2 +-
- include/asm-powerpc/ptrace.h        |    1 +
+ fs/select.c                         |   12 +-
+ include/asm-ia64/thread_info.h      |    5 +-
+ include/asm-powerpc/thread_info.h   |   17 +-
  include/asm-s390/thread_info.h      |    2 +-
- include/asm-sparc64/ptrace.h        |    2 +
  include/asm-x86/ptrace.h            |    2 +
+ include/asm-x86/thread_info_32.h    |   13 +-
+ include/asm-x86/thread_info_64.h    |   13 +-
+ include/linux/compat.h              |    5 +-
  include/linux/init_task.h           |    3 -
- include/linux/ptrace.h              |   71 +-
- include/linux/sched.h               |   46 +-
- include/linux/thread_info.h         |   10 +-
- include/linux/tracehook.h           |  493 ++++++++
+ include/linux/ptrace.h              |   70 +-
+ include/linux/sched.h               |   38 +-
+ include/linux/thread_info.h         |   27 +-
+ include/linux/tracehook.h           |  507 ++++++++
  include/linux/utrace.h              |  544 ++++++++
  init/Kconfig                        |   29 +
  kernel/Makefile                     |    1 +
  kernel/compat.c                     |    3 +-
- kernel/exit.c                       |  371 +++---
+ kernel/exit.c                       |  403 +++----
  kernel/fork.c                       |   72 +-
- kernel/ptrace.c                     | 2112 +++++++++++++++++++++++++-------
- kernel/signal.c                     |  288 +----
+ kernel/ptrace.c                     | 2129 +++++++++++++++++++++++++-------
+ kernel/signal.c                     |  285 +----
  kernel/sys_ni.c                     |    4 +
  kernel/utrace.c                     | 2377 +++++++++++++++++++++++++++++++++++
  mm/nommu.c                          |    4 +-
  security/selinux/hooks.c            |   59 +-
  security/selinux/include/objsec.h   |    1 -
- 58 files changed, 6306 insertions(+), 1287 deletions(-)
+ 81 files changed, 6535 insertions(+), 1421 deletions(-)
 
 diff --git a/Documentation/DocBook/Makefile b/Documentation/DocBook/Makefile
 index 300e170..7cf3afc 100644  
@@ -687,6 +708,274 @@
 +sure which event callbacks it will or won't see after utrace_set_flags
 +has returned.  By checking for errors, it can know whether to clean up
 +its data structures immediately or to let its callbacks do the work.
+diff --git a/arch/alpha/kernel/ptrace.c b/arch/alpha/kernel/ptrace.c
+index 1e9ad52..7dc30f5 100644  
+--- a/arch/alpha/kernel/ptrace.c
++++ b/arch/alpha/kernel/ptrace.c
+@@ -260,11 +260,12 @@ void ptrace_disable(struct task_struct *
+ 	ptrace_cancel_bpt(child);
+ }
+ 
+-long arch_ptrace(struct task_struct *child, long request, long addr, long data)
++int arch_ptrace(struct task_struct *child, long request, long addr, long data,
++		long *retval)
+ {
+ 	unsigned long tmp;
+ 	size_t copied;
+-	long ret;
++	int ret;
+ 
+ 	switch (request) {
+ 	/* When I and D space are separate, these will need to be fixed.  */
+@@ -275,14 +276,14 @@ long arch_ptrace(struct task_struct *chi
+ 		if (copied != sizeof(tmp))
+ 			break;
+ 		
+-		force_successful_syscall_return();
+-		ret = tmp;
++		ret = 0;
++		*retval = tmp;
+ 		break;
+ 
+ 	/* Read register number ADDR. */
+ 	case PTRACE_PEEKUSR:
+-		force_successful_syscall_return();
+-		ret = get_reg(child, addr);
++		ret = 0;
++		*retval = get_reg(child, addr);
+ 		DBG(DBG_MEM, ("peek $%ld->%#lx\n", addr, ret));
+ 		break;
+ 
+@@ -343,7 +344,7 @@ long arch_ptrace(struct task_struct *chi
+ 		break;
+ 
+ 	default:
+-		ret = ptrace_request(child, request, addr, data);
++		ret = 1;
+ 		break;
+ 	}
+ 	return ret;
+diff --git a/arch/arm/kernel/ptrace.c b/arch/arm/kernel/ptrace.c
+index 4b05dc5..938be29 100644  
+--- a/arch/arm/kernel/ptrace.c
++++ b/arch/arm/kernel/ptrace.c
+@@ -655,7 +655,8 @@ static int ptrace_setcrunchregs(struct t
+ }
+ #endif
+ 
+-long arch_ptrace(struct task_struct *child, long request, long addr, long data)
++int arch_ptrace(struct task_struct *child, long request, long addr, long data,
++		long *retval)
+ {
+ 	int ret;
+ 
+@@ -778,7 +779,7 @@ long arch_ptrace(struct task_struct *chi
+ #endif
+ 
+ 		default:
+-			ret = ptrace_request(child, request, addr, data);
++			ret = 1;
+ 			break;
+ 	}
+ 
+diff --git a/arch/avr32/kernel/ptrace.c b/arch/avr32/kernel/ptrace.c
+index 1fed38f..5ce2ff7 100644  
+--- a/arch/avr32/kernel/ptrace.c
++++ b/arch/avr32/kernel/ptrace.c
[...3020 lines suppressed...]
++			ret = rc;
++		else
++			force_successful_syscall_return();
 +		put_task_struct(child);
-+	}
+ 	}
+ 
+-	ret = ptrace_check_attach(child, request == PTRACE_KILL);
+-	if (!ret)
+-		ret = compat_arch_ptrace(child, request, addr, data);
  
 - out_put_task_struct:
 -	put_task_struct(child);
@@ -6349,7 +7512,7 @@
  
  #endif	/* CONFIG_COMPAT */
 diff --git a/kernel/signal.c b/kernel/signal.c
-index 6af1210..2fdb5fc 100644  
+index 6af1210..4ede33b 100644  
 --- a/kernel/signal.c
 +++ b/kernel/signal.c
 @@ -22,6 +22,7 @@
@@ -6667,7 +7830,7 @@
  		read_lock(&tasklist_lock);
  		do_notify_parent_cldstop(current, CLD_STOPPED);
  		read_unlock(&tasklist_lock);
-@@ -1780,44 +1647,24 @@ relock:
+@@ -1780,44 +1647,25 @@ relock:
  		    do_signal_stop(0))
  			goto relock;
  
@@ -6678,7 +7841,19 @@
 -
 -		if ((current->ptrace & PT_PTRACED) && signr != SIGKILL) {
 -			ptrace_signal_deliver(regs, cookie);
--
++		/*
++		 * Tracing can induce an artifical signal and choose sigaction.
++		 * The return value in @signr determines the default action,
++		 * but @info->si_signo is the signal number we will report.
++		 */
++		signr = tracehook_get_signal(current, regs, info, return_ka);
++		if (unlikely(signr < 0))
++			goto relock;
++		if (unlikely(signr != 0))
++			ka = return_ka;
++		else {
++			signr = dequeue_signal(current, mask, info);
+ 
 -			/* Let the debugger run.  */
 -			ptrace_stop(signr, 0, info);
 -
@@ -6700,27 +7875,14 @@
 -				info->si_pid = task_pid_vnr(current->parent);
 -				info->si_uid = current->parent->uid;
 -			}
--
++			if (!signr)
++				break; /* will return 0 */
+ 
 -			/* If the (new) signal is now blocked, requeue it.  */
 -			if (sigismember(&current->blocked, signr)) {
 -				specific_send_sig_info(signr, info, current);
 -				continue;
 -			}
-+		/*
-+		 * Tracing can induce an artifical signal and choose sigaction.
-+		 * The return value in signr determines the default action,
-+		 * but info->si_signo is the signal number we will report.
-+		 */
-+		signr = tracehook_get_signal(current, regs, info, return_ka);
-+		if (unlikely(signr < 0))
-+			goto relock;
-+		if (unlikely(signr != 0))
-+			ka = return_ka;
-+		else {
-+			signr = dequeue_signal(current, mask, info);
-+
-+			if (!signr)
-+				break; /* will return 0 */
 +			ka = &current->sighand->action[signr-1];
  		}
  
@@ -6728,7 +7890,7 @@
  		if (ka->sa.sa_handler == SIG_IGN) /* Do nothing.  */
  			continue;
  		if (ka->sa.sa_handler != SIG_DFL) {
-@@ -1827,6 +1674,7 @@ relock:
+@@ -1827,6 +1675,7 @@ relock:
  			if (ka->sa.sa_flags & SA_ONESHOT)
  				ka->sa.sa_handler = SIG_DFL;
  
@@ -6736,7 +7898,7 @@
  			break; /* will return non-zero "signr" value */
  		}
  
-@@ -1864,7 +1712,7 @@ relock:
+@@ -1864,7 +1713,7 @@ relock:
  				spin_lock_irq(&current->sighand->siglock);
  			}
  
@@ -6745,7 +7907,7 @@
  				/* It released the siglock.  */
  				goto relock;
  			}
-@@ -1882,9 +1730,10 @@ relock:
+@@ -1882,9 +1731,10 @@ relock:
  		 * Anything else is fatal, maybe with a core dump.
  		 */
  		current->flags |= PF_SIGNALED;
@@ -6758,7 +7920,7 @@
  			/*
  			 * If it was able to dump core, this kills all
  			 * other threads in the group and synchronizes with
-@@ -1893,13 +1742,13 @@ relock:
+@@ -1893,13 +1743,13 @@ relock:
  			 * first and our do_group_exit call below will use
  			 * that value and ignore the one we pass it.
  			 */
@@ -6774,7 +7936,7 @@
  		/* NOTREACHED */
  	}
  	spin_unlock_irq(&current->sighand->siglock);
-@@ -1953,7 +1802,6 @@ EXPORT_SYMBOL_GPL(dequeue_signal);
+@@ -1953,7 +1803,6 @@ EXPORT_SYMBOL_GPL(dequeue_signal);
  EXPORT_SYMBOL(flush_signals);
  EXPORT_SYMBOL(force_sig);
  EXPORT_SYMBOL(kill_proc);
@@ -6782,7 +7944,7 @@
  EXPORT_SYMBOL(send_sig);
  EXPORT_SYMBOL(send_sig_info);
  EXPORT_SYMBOL(sigprocmask);
-@@ -2610,7 +2458,7 @@ asmlinkage long sys_rt_sigsuspend(sigset
+@@ -2610,7 +2459,7 @@ asmlinkage long sys_rt_sigsuspend(sigset
  
  	current->state = TASK_INTERRUPTIBLE;
  	schedule();
@@ -9212,7 +10374,7 @@
  
  	return vm_flags;
 diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
-index 41a049f..44b756b 100644  
+index d39b59c..43cb7c3 100644  
 --- a/security/selinux/hooks.c
 +++ b/security/selinux/hooks.c
 @@ -24,7 +24,7 @@
@@ -9233,7 +10395,7 @@
  	task->security = tsec;
  
  	return 0;
-@@ -1638,19 +1638,13 @@ static inline u32 file_to_av(struct file
+@@ -1645,19 +1645,13 @@ static inline u32 file_to_av(struct file
  
  static int selinux_ptrace(struct task_struct *parent, struct task_struct *child)
  {
@@ -9254,7 +10416,7 @@
  }
  
  static int selinux_capget(struct task_struct *target, kernel_cap_t *effective,
-@@ -2119,12 +2113,25 @@ static void selinux_bprm_apply_creds(str
+@@ -2126,12 +2120,25 @@ static void selinux_bprm_apply_creds(str
  		/* Check for ptracing, and update the task SID if ok.
  		   Otherwise, leave SID unchanged and kill. */
  		if (unsafe & (LSM_UNSAFE_PTRACE | LSM_UNSAFE_PTRACE_CAP)) {
@@ -9286,7 +10448,7 @@
  			}
  		}
  		tsec->sid = sid;
-@@ -2207,7 +2214,7 @@ static void selinux_bprm_post_apply_cred
+@@ -2214,7 +2221,7 @@ static void selinux_bprm_post_apply_cred
  
  	/* Wake up the parent if it is waiting so that it can
  	   recheck wait permission to the new task SID. */
@@ -9295,7 +10457,7 @@
  }
  
  /* superblock security operations */
-@@ -3080,11 +3087,6 @@ static int selinux_task_alloc_security(s
+@@ -3087,11 +3094,6 @@ static int selinux_task_alloc_security(s
  	tsec2->keycreate_sid = tsec1->keycreate_sid;
  	tsec2->sockcreate_sid = tsec1->sockcreate_sid;
  
@@ -9307,7 +10469,7 @@
  	return 0;
  }
  
-@@ -5050,6 +5052,7 @@ static int selinux_setprocattr(struct ta
+@@ -5057,6 +5059,7 @@ static int selinux_setprocattr(struct ta
  			       char *name, void *value, size_t size)
  {
  	struct task_security_struct *tsec;
@@ -9315,7 +10477,7 @@
  	u32 sid = 0;
  	int error;
  	char *str = value;
-@@ -5138,18 +5141,24 @@ static int selinux_setprocattr(struct ta
+@@ -5145,18 +5148,24 @@ static int selinux_setprocattr(struct ta
  		/* Check for ptracing, and update the task SID if ok.
  		   Otherwise, leave SID unchanged and fail. */
  		task_lock(p);




More information about the fedora-extras-commits mailing list