Dave Jones [Wed, 14 Apr 2004 03:21:28 +0000 (20:21 -0700)]
[PATCH] isofs buffer overflow fix
Merged in 2.4, and various vendor kernels..
iDefense reported a buffer overflow flaw in the ISO9660 filesystem code.
An attacker could create a malicious filesystem in such a way that they
could gain root privileges if that filesystem is mounted. The Common
Vulnerabilities and Exposures project (cve.mitre.org) has assigned the name
CAN-2004-0109 to this issue.
Ernie Petrides came up with the following patch which I fixed up a slight
reject in to apply to 2.6. Otherwise, unchanged from the 2.4 patch.
- Update defconfig
- Fix some problems in ROM resource scanning (Rene Herman)
- Initialize APIC id of CPU 0 (Venkatesh Pallipadi)
- Always enable swiotlb for GART_IOMMU
- Fix compilation without IOMMU_GART
- Remove nodes_present; use standard node_online_map instead.
This also fixes a bug with no memory on node 0.
- Switch node<->cpu mapping to arrays. This fixes some awkward
special cases with no nodes and empty nodes.
- Move K8 fallback node setup to common code
- Eliminate old fake_node.
- Fix wrong fields in MCE handling (Marc Bevand)
- Make pci_dma_consistent behave more similar to i386 to fix Alsa
Andrew Morton [Tue, 13 Apr 2004 11:49:20 +0000 (04:49 -0700)]
[PATCH] update fix for potential integer overflow in zoran driver
From: Dave Jones <davej@redhat.com>
2.4 already had this fixed, but uses a somewhat larger value to clip at.
For uniformity sake, perhaps they should be the same? Patch below makes
it match 2.4-bk
Andrew Morton [Tue, 13 Apr 2004 11:48:41 +0000 (04:48 -0700)]
[PATCH] jbd copyout fix
When I converted journal_write_metadata_buffer() to kmap_atomic() I screwed
up the handling of the copyout buffers - we're currently writing four zeroes
into the user's page rather than into the data which is to be written to the
journal (oops).
Net effect: any block which starts with 0xC03B3998 gets scribbled on in
data=journal mode.
ide_ioreg_t is deprecated and hasn't been used by IDE driver for some time.
Use unsigned long directly on alpha, arm26, arm, mips, parisc, ppc64 and sh.
asm-ia64/ide.h (ide_ioreg_t is unsigned short) and asm-m68knommu/ide.h
(broken - ide_ioreg_t is not defined) are the only users of ide_ioreg_t left.
[PATCH] ide-disk.c: workaround for bogus LBA48 drives
From: Geert Uytterhoeven <geert@linux-m68k.org>
Apparently some IDE drives (e.g. a pile of 80 GB ST380020ACE drives I have
access to) advertise to support LBA48, but don't, causing kernels that support
LBA48 (i.e. anything newer than 2.4.18, including 2.4.25 and 2.6.4) to fail on
them. Older kernels (including 2.2.20 on the Debian woody CDs) work fine.
Check for id->lba_capacity_2 being non-zero in idedisk_supports_lba48().
Don Fry [Tue, 13 Apr 2004 10:06:34 +0000 (06:06 -0400)]
[PATCH] pcnet32 fix hang/crash with loopback test
If the pcnet32 interface is not up, running the loopback test may hang or
crash the system. This patch provided by Jim Lewis fixes that problem.
Tested on ia32 and ppc systems.
[PATCH] e1000: remove polarity reversal workaround for forced 10H/10F links
Adding this caused the adapter to fail while operating at 10 mbps, half
duplex. Hence the fix is not complete. We are still investigating a more
complete fix for the polarity reversal issue.
[PATCH] e1000: fix eeprom update to include e1000_standby_eeprom
A Bug in e1000_spi_eeprom_ready where the Chip Select bit wasn't being
toggled after every status register read (if the eeprom wasn't ready after
the first status register read). The call to e1000_standby_eeprom manages
the CS bit correctly
Andrew Morton [Tue, 13 Apr 2004 02:26:22 +0000 (19:26 -0700)]
[PATCH] ppc64: Fix ibmveth.c compilation
From: Paul Mackerras <paulus@samba.org>
This patch changes PCI_DMA_TODEVICE to DMA_TO_DEVICE in a couple of
places in drivers/net/ibmveth.c, since it doesn't compile without this
change and it does compile with it. It also reformats a couple of
over-long lines in the vicinity of the other changes.
Andrew Morton [Tue, 13 Apr 2004 02:24:35 +0000 (19:24 -0700)]
[PATCH] Wrong return value in hfs_fill_super
From: Nick Wellnhofer <wellnhofer@aevum.de>
hfs_fill_super in 2.6.5 returns -EIO instead of -EINVAL if a valid supe=
block isn't found. So mount_block_root in init/do_mounts.c bails out before
trying to mount the root device as XFS.
Andrew Morton [Tue, 13 Apr 2004 02:24:22 +0000 (19:24 -0700)]
[PATCH] m68knommu: fixes to the 68328 DragonBall serial driver
From: <gerg@snapgear.com>
A few fixes for the 68328 "DragonBall" serial driver:
. use irqreturn_t for interrupt handlers
. correct a few variable types (stop compiler warnings)
. correctly use return values from put_user(), get_user() and copy_to_user()
Andrew Morton [Tue, 13 Apr 2004 02:24:08 +0000 (19:24 -0700)]
[PATCH] m68knommu: fixes to the ColdFire serial driver
From: <gerg@snapgear.com>
A whole bunch of fixes for the ColdFire serial driver:
. remove unused CONFIG_LEDMAN code
. reformat port definitions to new style structure init
. change "addr" field type to reduce casting in ColdFire serial driver
. cleanup locking problems in mcfrs_write().
. implement fraction baud rate clock support for hardware that
supports it (namely the ColdFire 5272)
. implement wait_until_sent, some ColdFire parts of hardware support
for this (again the 5272).
. correctly use return values from put_user(), get_user() and copy_to_user()
Andrew Morton [Tue, 13 Apr 2004 02:22:50 +0000 (19:22 -0700)]
[PATCH] fix vga16fb.c frame buffer bad memory mapping
From: Vincent Sanders <vince@kyllikki.org>
The vga16fb driver uses a direct ioremap on 0xa00000 to gain access to the
vga card. This is wrong on architectures other than x86, every other driver
uses VGA_MAP_MEM macro from vga.h to ensure the correct memory mapping.
Andrew Morton [Tue, 13 Apr 2004 02:22:37 +0000 (19:22 -0700)]
[PATCH] shrink VFS hash sizes on small machines
From: Matt Mackall <mpm@selenic.com>
Base hash sizes on available memory rather than total memory. An
additional 50% above current used memory is considered reserved for the
purposes of hash sizing to compensate for the hashes themselves and the
remainder of kernel and userspace initialization.
Andrew Morton [Tue, 13 Apr 2004 02:21:59 +0000 (19:21 -0700)]
[PATCH] kbuild: Create .tmp_versions when building external modules
From: Sam Ravnborg <sam@ravnborg.org>
When building external modules the $PWD/.tmp_versions directory is used.
The .tmp_versions directory in the kernel tree cannot be used because this
would clutter up the kernel tree especially when more than one external
module is being build for the same kernel tree.
This patch make sure to create $PWD/.tmp_versions, and to delete it during
make clean. It also removes warning about 'messed with SUBDIRS', this is
no longer relevant when .tmp_versions is made outside the kernel tree.
M68k TLB fixes from Roman Zippel:
- Check current->active_mm for currently active mm
- Set correct context to flush the right ATC entry
This is especially important for kswapd to correctly flush unmapped entries (it
caused random segfaults during large compiles)
Randy Dunlap [Mon, 12 Apr 2004 19:03:14 +0000 (20:03 +0100)]
[ARM] use errno #defines in assembly
Patch from: Randy Dunlap
From: Danilo Piazzalunga
Some assembly code (on various archs) either
1. uses hardcoded errno numbers instead of the canonical macro
names, or
2. defines them locally, instead of including the appropriate
header (while including other headers).
This patch "fixes" such usage in
- getuser.S for arm
- putuser.S for arm
Andrew Morton [Mon, 12 Apr 2004 08:07:11 +0000 (01:07 -0700)]
[PATCH] Oprofile: ARM/XScale PMU driver
From: Zwane Mwaikambo <zwane@linuxpower.ca>
The following patch adds support for the XScale performance monitoring unit
to OProfile. It uses not only the performance monitoring counters, but
also the clock cycle counter (CCNT) allowing for upto 5 usable counters.
The code has been developed and tested on an IOP331 (hardware courtesy of
Intel) therefore i haven't been able to test it on XScale PMU1 systems.
Testing on said systems would be appreciated, and if done, please uncomment
the #define DEBUG line at the top of op_model_xscale.c
OProfile userspace support has already been committed and should be
available via CVS.
Andrew Morton [Mon, 12 Apr 2004 08:06:06 +0000 (01:06 -0700)]
[PATCH] Add CONFIG_SYSFS
From: Patrick Mochel <mochel@digitalimplant.org>
Here is a patch to make sysfs optional. Note that with CONFIG_SYSFS=n you
must specify the boot device's major:minor on the kernel boot command line
with
root=03:01
For embedded systems, it will save a significant amount of memory during
runtime. And, it saves 4k from the built kernel image for me.