From b51f3774e87e45ea13b809acb0d3f356f347fc41 Mon Sep 17 00:00:00 2001 From: Greg KH Date: Wed, 11 May 2005 22:00:17 -0700 Subject: [PATCH] Initial commit 'add 5 2.6.11.y proposed patches.' --- cramfs.patch | 32 +++++++++++++++++++ ebony.patch | 73 ++++++++++++++++++++++++++++++++++++++++++ mips-ptrace.patch | 47 +++++++++++++++++++++++++++ oprofile.patch | 35 ++++++++++++++++++++ st.patch | 81 +++++++++++++++++++++++++++++++++++++++++++++++ 5 files changed, 268 insertions(+) create mode 100644 cramfs.patch create mode 100644 ebony.patch create mode 100644 mips-ptrace.patch create mode 100644 oprofile.patch create mode 100644 st.patch diff --git a/cramfs.patch b/cramfs.patch new file mode 100644 index 00000000000..9ef3cc045e8 --- /dev/null +++ b/cramfs.patch @@ -0,0 +1,32 @@ +From akpm@osdl.org Fri Mar 4 13:22:03 2005 +Subject: [patch 1/5] cramfs: small stat(2) fix +To: greg@kroah.com +Cc: linux-kernel@vger.kernel.org, akpm@osdl.org, eric@lammerts.org +From: akpm@osdl.org +Date: Fri, 04 Mar 2005 13:16:54 -0800 +Lines: 23 + +From: Eric Lammerts + +When I stat(2) a device node on a cramfs, the st_blocks field is bogus +(it's derived from the size field which in this case holds the major/minor +numbers). This makes du(1) output completely wrong. + +Signed-off-by: Eric Lammerts +Signed-off-by: Andrew Morton +Signed-off-by: Greg Kroah-Hartman + + +diff -puN fs/cramfs/inode.c~cramfs-small-stat2-fix fs/cramfs/inode.c +--- 25/fs/cramfs/inode.c~cramfs-small-stat2-fix 2005-03-04 13:15:57.000000000 -0800 ++++ 25-akpm/fs/cramfs/inode.c 2005-03-04 13:15:57.000000000 -0800 +@@ -70,6 +70,7 @@ static struct inode *get_cramfs_inode(st + inode->i_data.a_ops = &cramfs_aops; + } else { + inode->i_size = 0; ++ inode->i_blocks = 0; + init_special_inode(inode, inode->i_mode, + old_decode_dev(cramfs_inode->size)); + } +_ + diff --git a/ebony.patch b/ebony.patch new file mode 100644 index 00000000000..b5fe8a3538f --- /dev/null +++ b/ebony.patch @@ -0,0 +1,73 @@ +From akpm@osdl.org Fri Mar 4 13:22:08 2005 +Subject: [patch 3/5] ppc32: Compilation fixes for Ebony, Luan and Ocotea +To: greg@kroah.com +Cc: linux-kernel@vger.kernel.org, akpm@osdl.org, mporter@kernel.crashing.org, + gjaeger@sysgo.com +From: akpm@osdl.org +Date: Fri, 04 Mar 2005 13:16:56 -0800 +Lines: 63 + + +From: Matt Porter + +this patch fixes the problem, that the current kernel (linux-2.6.11-rc5) +could not be compiled, when "support for early boot texts over serial port" +(CONFIG_SERIAL_TEXT_DEBUG=y) is active. + +Signed-off-by: Gerhard Jaeger +Signed-off-by: Matt Porter +Signed-off-by: Andrew Morton +Signed-off-by: Greg Kroah-Hartman +--- + + 25-akpm/arch/ppc/platforms/4xx/ebony.h | 4 ++-- + 25-akpm/arch/ppc/platforms/4xx/luan.h | 6 +++--- + 25-akpm/arch/ppc/platforms/4xx/ocotea.h | 4 ++-- + 3 files changed, 7 insertions(+), 7 deletions(-) + +diff -puN arch/ppc/platforms/4xx/ebony.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea arch/ppc/platforms/4xx/ebony.h +--- 25/arch/ppc/platforms/4xx/ebony.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea 2005-03-04 13:16:17.000000000 -0800 ++++ 25-akpm/arch/ppc/platforms/4xx/ebony.h 2005-03-04 13:16:17.000000000 -0800 +@@ -61,8 +61,8 @@ + */ + + /* OpenBIOS defined UART mappings, used before early_serial_setup */ +-#define UART0_IO_BASE (u8 *) 0xE0000200 +-#define UART1_IO_BASE (u8 *) 0xE0000300 ++#define UART0_IO_BASE 0xE0000200 ++#define UART1_IO_BASE 0xE0000300 + + /* external Epson SG-615P */ + #define BASE_BAUD 691200 +diff -puN arch/ppc/platforms/4xx/luan.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea arch/ppc/platforms/4xx/luan.h +--- 25/arch/ppc/platforms/4xx/luan.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea 2005-03-04 13:16:17.000000000 -0800 ++++ 25-akpm/arch/ppc/platforms/4xx/luan.h 2005-03-04 13:16:17.000000000 -0800 +@@ -47,9 +47,9 @@ + #define RS_TABLE_SIZE 3 + + /* PIBS defined UART mappings, used before early_serial_setup */ +-#define UART0_IO_BASE (u8 *) 0xa0000200 +-#define UART1_IO_BASE (u8 *) 0xa0000300 +-#define UART2_IO_BASE (u8 *) 0xa0000600 ++#define UART0_IO_BASE 0xa0000200 ++#define UART1_IO_BASE 0xa0000300 ++#define UART2_IO_BASE 0xa0000600 + + #define BASE_BAUD 11059200 + #define STD_UART_OP(num) \ +diff -puN arch/ppc/platforms/4xx/ocotea.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea arch/ppc/platforms/4xx/ocotea.h +--- 25/arch/ppc/platforms/4xx/ocotea.h~ppc32-compilation-fixes-for-ebony-luan-and-ocotea 2005-03-04 13:16:17.000000000 -0800 ++++ 25-akpm/arch/ppc/platforms/4xx/ocotea.h 2005-03-04 13:16:17.000000000 -0800 +@@ -56,8 +56,8 @@ + #define RS_TABLE_SIZE 2 + + /* OpenBIOS defined UART mappings, used before early_serial_setup */ +-#define UART0_IO_BASE (u8 *) 0xE0000200 +-#define UART1_IO_BASE (u8 *) 0xE0000300 ++#define UART0_IO_BASE 0xE0000200 ++#define UART1_IO_BASE 0xE0000300 + + #define BASE_BAUD 11059200/16 + #define STD_UART_OP(num) \ +_ + diff --git a/mips-ptrace.patch b/mips-ptrace.patch new file mode 100644 index 00000000000..c213e5e921e --- /dev/null +++ b/mips-ptrace.patch @@ -0,0 +1,47 @@ +From akpm@osdl.org Fri Mar 4 13:22:06 2005 +Subject: [patch 4/5] audit mips fix +To: greg@kroah.com +Cc: linux-kernel@vger.kernel.org, akpm@osdl.org, yuasa@hh.iij4u.or.jp +From: akpm@osdl.org +Date: Fri, 04 Mar 2005 13:16:57 -0800 +Lines: 38 + + +From: Yoichi Yuasa + + CC arch/mips/kernel/ptrace.o +arch/mips/kernel/ptrace.c: In function 'do_syscall_trace': +arch/mips/kernel/ptrace.c:310: warning: implicit declaration of function 'audit_syscall_entry' +arch/mips/kernel/ptrace.c:310: error: 'struct pt_regs' has no member named 'orig_eax' +arch/mips/kernel/ptrace.c:314: warning: implicit declaration of function 'audit_syscall_exit' + +Signed-off-by: Yoichi Yuasa +Signed-off-by: Andrew Morton +Signed-off-by: Greg Kroah-Hartman +--- + + 25-akpm/arch/mips/kernel/ptrace.c | 3 ++- + 1 files changed, 2 insertions(+), 1 deletion(-) + +diff -puN arch/mips/kernel/ptrace.c~audit-mips-fix arch/mips/kernel/ptrace.c +--- 25/arch/mips/kernel/ptrace.c~audit-mips-fix 2005-03-04 13:16:25.000000000 -0800 ++++ 25-akpm/arch/mips/kernel/ptrace.c 2005-03-04 13:16:25.000000000 -0800 +@@ -21,6 +21,7 @@ + #include + #include + #include ++#include + #include + #include + #include +@@ -307,7 +308,7 @@ asmlinkage void do_syscall_trace(struct + { + if (unlikely(current->audit_context)) { + if (!entryexit) +- audit_syscall_entry(current, regs->orig_eax, ++ audit_syscall_entry(current, regs->regs[2], + regs->regs[4], regs->regs[5], + regs->regs[6], regs->regs[7]); + else +_ + diff --git a/oprofile.patch b/oprofile.patch new file mode 100644 index 00000000000..57785ed792c --- /dev/null +++ b/oprofile.patch @@ -0,0 +1,35 @@ +From galak@freescale.com Fri Mar 4 11:14:53 2005 +Date: Fri, 4 Mar 2005 13:09:18 -0600 (CST) +From: Kumar Gala +To: akpm@osdl.org, greg@kroah.com +cc: linuxppc-embedded@ozlabs.org, linux-kernel@vger.kernel.org +Subject: [PATCH] ppc32: trivial fix for e500 oprofile build +Lines: 26 + +Fix for trivial fix for 2.6.11 oprofile compilation on e500 based ppc. + +Signed-off-by: Andy Fleming +Signed-off-by: Kumar Gala +Signed-off-by: Greg Kroah-Hartman + +diff -Nru a/arch/ppc/oprofile/op_model_fsl_booke.c b/arch/ppc/oprofile/op_model_fsl_booke.c +--- a/arch/ppc/oprofile/op_model_fsl_booke.c 2005-03-04 13:02:52 -06:00 ++++ b/arch/ppc/oprofile/op_model_fsl_booke.c 2005-03-04 13:02:52 -06:00 +@@ -150,7 +150,6 @@ + int is_kernel; + int val; + int i; +- unsigned int cpu = smp_processor_id(); + + /* set the PMM bit (see comment below) */ + mtmsr(mfmsr() | MSR_PMM); +@@ -162,7 +161,7 @@ + val = ctr_read(i); + if (val < 0) { + if (oprofile_running && ctr[i].enabled) { +- oprofile_add_sample(pc, is_kernel, i, cpu); ++ oprofile_add_pc(pc, is_kernel, i); + ctr_write(i, reset_value[i]); + } else { + ctr_write(i, 0); + diff --git a/st.patch b/st.patch new file mode 100644 index 00000000000..2ddac288c06 --- /dev/null +++ b/st.patch @@ -0,0 +1,81 @@ +From akpm@osdl.org Fri Mar 4 13:22:11 2005 +Return-Path: +Subject: [patch 5/5] make st seekable again +To: greg@kroah.com +Cc: linux-kernel@vger.kernel.org, akpm@osdl.org, kai.makisara@kolumbus.fi +From: akpm@osdl.org +Date: Fri, 04 Mar 2005 13:16:58 -0800 +Lines: 71 + + +From: Kai Makisara + +Apparently `tar' errors out if it cannot perform lseek() against a tape. Work +around that in-kernel. + +Signed-off-by: Kai Makisara +Signed-off-by: Andrew Morton +Signed-off-by: Greg Kroah-Hartman +--- + + 25-akpm/drivers/ide/ide-tape.c | 8 +++++++- + 25-akpm/drivers/scsi/osst.c | 8 +++++++- + 25-akpm/drivers/scsi/st.c | 8 +++++++- + 3 files changed, 21 insertions(+), 3 deletions(-) + +diff -puN drivers/ide/ide-tape.c~make-st-seekable-again drivers/ide/ide-tape.c +--- 25/drivers/ide/ide-tape.c~make-st-seekable-again 2005-03-04 13:16:32.000000000 -0800 ++++ 25-akpm/drivers/ide/ide-tape.c 2005-03-04 13:16:32.000000000 -0800 +@@ -4100,7 +4100,13 @@ static int idetape_chrdev_open (struct i + idetape_pc_t pc; + int retval; + +- nonseekable_open(inode, filp); ++ /* ++ * We really want to do nonseekable_open(inode, filp); here, but some ++ * versions of tar incorrectly call lseek on tapes and bail out if that ++ * fails. So we disallow pread() and pwrite(), but permit lseeks. ++ */ ++ filp->f_mode &= ~(FMODE_PREAD | FMODE_PWRITE); ++ + #if IDETAPE_DEBUG_LOG + printk(KERN_INFO "ide-tape: Reached idetape_chrdev_open\n"); + #endif /* IDETAPE_DEBUG_LOG */ +diff -puN drivers/scsi/st.c~make-st-seekable-again drivers/scsi/st.c +--- 25/drivers/scsi/st.c~make-st-seekable-again 2005-03-04 13:16:32.000000000 -0800 ++++ 25-akpm/drivers/scsi/st.c 2005-03-04 13:16:32.000000000 -0800 +@@ -1004,7 +1004,13 @@ static int st_open(struct inode *inode, + int dev = TAPE_NR(inode); + char *name; + +- nonseekable_open(inode, filp); ++ /* ++ * We really want to do nonseekable_open(inode, filp); here, but some ++ * versions of tar incorrectly call lseek on tapes and bail out if that ++ * fails. So we disallow pread() and pwrite(), but permit lseeks. ++ */ ++ filp->f_mode &= ~(FMODE_PREAD | FMODE_PWRITE); ++ + write_lock(&st_dev_arr_lock); + if (dev >= st_dev_max || scsi_tapes == NULL || + ((STp = scsi_tapes[dev]) == NULL)) { +diff -puN drivers/scsi/osst.c~make-st-seekable-again drivers/scsi/osst.c +--- 25/drivers/scsi/osst.c~make-st-seekable-again 2005-03-04 13:16:32.000000000 -0800 ++++ 25-akpm/drivers/scsi/osst.c 2005-03-04 13:16:32.000000000 -0800 +@@ -4318,7 +4318,13 @@ static int os_scsi_tape_open(struct inod + int dev = TAPE_NR(inode); + int mode = TAPE_MODE(inode); + +- nonseekable_open(inode, filp); ++ /* ++ * We really want to do nonseekable_open(inode, filp); here, but some ++ * versions of tar incorrectly call lseek on tapes and bail out if that ++ * fails. So we disallow pread() and pwrite(), but permit lseeks. ++ */ ++ filp->f_mode &= ~(FMODE_PREAD | FMODE_PWRITE); ++ + write_lock(&os_scsi_tapes_lock); + if (dev >= osst_max_dev || os_scsi_tapes == NULL || + (STp = os_scsi_tapes[dev]) == NULL || !STp->device) { +_ + -- 2.47.3