/proc shows the wrong PID as parent in the following case
Process A creates Threads 1 & 2 (using pthread_create) Thread 2 then forks
and execs process B getppid() for Process B shows Process A (rightly) as
parent, however /proc/B/status shows Thread 3 as PPid (incorrect).
Use, in the rb_entry definition, the container_of macro instead of
reinventing the wheel; compared to using offset_of() as I did in the prev.
version, it has type safety checking.
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade_spam@yahoo.it> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Dell's Virtual Floppy (system management presents to the local system an
IDE floppy device, which is actually a floppy device in a remote system
connected over an IP link) exhibits this also, when connecting to a remote
floppy drive with no media present.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Hideo Aoki [Wed, 20 Oct 2004 01:36:51 +0000 (18:36 -0700)]
[PATCH] proc.txt cleanup
In Documentation/filesystems/proc.txt, explanation of /proc/meminfo is
described in section 1.3 (IDE devices in /proc/ide). I think that it
should be described in section 1.2 (Kernel data).
Hideo Aoki [Wed, 20 Oct 2004 01:36:36 +0000 (18:36 -0700)]
[PATCH] vm thrashing control tuning
This patch adds "swap_token_timeout" parameter in /proc/sys/vm. The
parameter means expired time of token. Unit of the value is HZ, and the
default value is the same as current SWAP_TOKEN_TIMEOUT (i.e. HZ * 300).
Matt Domsch [Wed, 20 Oct 2004 01:36:22 +0000 (18:36 -0700)]
[PATCH] EDD: use EXTENDED READ command, add CONFIG_EDD_SKIP_MBR
Some controller BIOSes have problems with the legacy int13 fn02 READ
SECTORS command. int13 fn42 EXTENDED READ is used in preference by most
boot loaders today, so lets use that. If EXTENDED READ fails or isn't
supported, fall back to READ SECTORS.
This hopefully resolves the three reports of BIOSes which would either
long-pause (30+ seconds) or hang completely on the legacy READ SECTORS
command.
This also adds CONFIG_EDD_SKIP_MBR to eliminate reading the MBR on each
BIOS-presented disk, in case there are further problems in this area.
Signed-off-by: Matt Domsch <Matt_Domsch@dell.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Ryan S. Arnold [Wed, 20 Oct 2004 01:36:07 +0000 (18:36 -0700)]
[PATCH] hvc_console fix to prevent oops and late hangup and write operations
This patch prevents execution of hvc_write() and hvc_hangup() after the tty
layer has executed a final hvc_close() against a device. This patch
provides a better method than was previously used. tty->driver_data is no
longer invalidated so we'll no longer get oopses when the tty layer allows
late hangup() and write() operations.
- Removed silly tty->driver_data = NULL; from hvc_close which prevents
possible oops in hvc_write() and hvc_hangup() due to improperly acting
ldisc close ordering.
- Added hp->count <= 0 check to hvc_write() and hvc_hangup() to prevent
execution of these function after hvc_close() has been invoked by the tty
layer. Same tty ldisc issues as above are the reason.
- Added some comments to clarify the situation.
- Awaiting a forth coming patch from Alan Cox which should clean up the
close ordering and prevent the late hangup and write ops from happening.
Signed-off-by: Ryan S. Arnold <rsa@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Duncan Sands [Wed, 20 Oct 2004 01:35:07 +0000 (18:35 -0700)]
[PATCH] firmware_class: avoid double free
The error exit path in request_firmware frees the allocated struct firmware
*firmware, which is good. What is not so good is that the value of
firmware has already been copied out to the caller as *firmware_p. The
risk is that the caller will pass this to release_firmware, a double free.
This is exactly what will happen if the caller copied the example code
[PATCH] Amifb: use new amifb:off logic to enhance audio experience
Amiga frame buffer: We used to have a local hack in fbmem.c to always call the
fbdev setup() routines, even when an fbdev was explicitly disabled on the
kernel command line (video=xxx:off). This allowed amifb to suspend the
monitor, but program the sync generator of the video controller in Denise/Lisa
to a 31 kHz/70 Hz mode, increasing the maximum audio playback frequency.
Thanks to the recently introduced fb_get_options() routine, we can kill the
local hack and just use the return value of fb_get_options().
Amiga frame buffer: The new convention (introduced in 2.6.9-rc1) requires that
the usable color depth for pseudocolor visuals is indicated by the lengths of
the color bitfields. Update amifb for this convention, and add a special case
for HAM (Hold-and-Modify) mode (colormap has 16 (HAM6) or 64 (HAM8) entries).
[PATCH] M68k: don't emit empty stack program header in vmlinux
Recent versions of ld add an empty stack program header to the kernel image,
which makes it incompatible with current m68k bootstrap loaders. Modify the
linker script to make sure we see only the program headers that are really
needed. (from Roman Zippel)
[PATCH] x86[64]: display phys_proc_id only when it is initialized
phys_proc_id gets initialized only when (smp_num_siblings > 1). But gets
printed even when (smp_num_siblings == 1). As a result we print incorrect
physical processor id in /proc/cpuinfo, when HT is disabled.
Oleg Nesterov [Wed, 20 Oct 2004 01:31:47 +0000 (18:31 -0700)]
[PATCH] detach_pid(): restore optimization
Kirill's kernel/pid.c rework broke optimization logic in detach_pid(). Non
zero return from __detach_pid() was used to indicate, that this pid can
probably be freed. Current version always (modulo idle threads) return non
zero value, thus resulting in unneccesary pid_hash scanning.
Also, uninlining __detach_pid() reduces pid.o text size from 2492 to 1600
bytes.
POSIX clocks are to be implemented in the following way according
to V3 of the Single Unix Specification:
1. CLOCK_PROCESS_CPUTIME_ID
Implementations shall also support the special clockid_t value
CLOCK_PROCESS_CPUTIME_ID, which represents the CPU-time clock of the
calling process when invoking one of the clock_*() or timer_*()
functions. For these clock IDs, the values returned by clock_gettime() and
specified by clock_settime() represent the amount of execution time of the
process associated with the clock.
2. CLOCK_THREAD_CPUTIME_ID
Implementations shall also support the special clockid_t value
CLOCK_THREAD_CPUTIME_ID, which represents the CPU-time clock of the
calling thread when invoking one of the clock_*() or timer_*()
functions. For these clock IDs, the values returned by clock_gettime()
and specified by clock_settime() shall represent the amount of
execution time of the thread associated with the clock.
These times mentioned are CPU processing times and not the time that has
passed since the startup of a process. Glibc currently provides its own
implementation of these two clocks which is designed to return the time
that passed since the startup of a process or a thread.
Moreover Glibc's clocks are bound to CPU timers which is problematic when the
frequency of the clock changes or the process is moved to a different
processor whose cpu timer may not be fully synchronized to the cpu timer
of the current CPU. This patchset results in a both clocks working reliably.
The patch also implements the access to other the thread and process clocks
of linux processes by using negative clockid's:
1. For CLOCK_PROCESS_CPUTIME_ID: -pid
2. For CLOCK_THREAD_CPUTIME_ID: -(pid + PID_MAX_LIMIT)
This allows
clock_getcpuclockid(pid) to return -pid
and
pthread_getcpuiclock(pid) to return -(pid + PID_MAX_LIMIT)
to allow access to the corresponding clocks.
Todo:
- The timer API to generate events by a non tick based timer is not
usable in its current state. The posix timer API seems to be only
useful at this point to define clock_get/set. Need to revise this.
- Implement timed interrupts in mmtimer after API is revised.
The mmtimer patch is unchanged from V6 and stays as is in 2.6.9-rc3-mm2.
But I expect to update the driver as soon as the interface to setup hardware
timer interrupts is usable.
Frank Hirtz [Wed, 20 Oct 2004 01:31:04 +0000 (18:31 -0700)]
[PATCH] Display committed memory limit and available in meminfo
The following patch will have the committed memory limit (per the current
overcommit ratio) and the amount of memory remaining under this limit
displayed in meminfo.
It's presently somewhat difficult to use the strict memory overcommit
settings as it's somewhat difficult to determine the amount of memory
remaining under the cap. This patch would make using strict overcommit a
good bit simpler.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
I have received positive feedback from various individuals who have applied my
BSD Secure Levels LSM patch, and so at this point I am submitting it to you
with a request to merge it in. Nothing has changed in this patch since when I
last posted it to the LKML, so I am not re-sending it there.
This first patch adds hooks to catch attempts to set the system clock back.
Signed-off-by: Michael A. Halcrow <mahalcro@us.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Roland McGrath [Wed, 20 Oct 2004 01:30:01 +0000 (18:30 -0700)]
[PATCH] move struct k_itimer out of linux/sched.h
I don't know why struct k_itimer was ever declared in sched.h; perhaps at
one time it was referenced by something else there. There is no need for
it now. This patch moves the struct where it belongs, in
linux/posix-timers.h. It has zero effect on anything except keeping the
source easier to read.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] vm: convert users of remap_page_range() under sound/ to use remap_pfn_range()
This patch converts all users of remap_page_range() under sound/ to use
remap_pfn_range(), with the exception of maestro3 changelogs, which are likely
expected to be preserved intact apart from additions (as most changelogs are),
regardless of API changes.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] vm: convert users of remap_page_range() under include/asm-*/ to use remap_pfn_range()
This patch converts uses of remap_page_range() via io_remap_page_range() in
include/asm-*/ to use remap_pfn_range(). io_remap_page_range() has a similar
physical address overflow issue that needs to be addressed later.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
[PATCH] vm: introduce remap_pfn_range() to replace remap_page_range()
This patch introduces remap_pfn_range(), destined to replace
remap_page_range(), to which all callers of remap_page_range() are converted
in the sequel.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:27:48 +0000 (18:27 -0700)]
[PATCH] nfsd4: move code to truncate on open to separate function
for OPEN with O_TRUNC, if the truncate fails, the open fails. for
nfs4_open_upgrade, this means undo the get_write_access. for new OPENs, this
means release the newly created stateid.
Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:27:34 +0000 (18:27 -0700)]
[PATCH] nfsd4: fix putrootfh return
Thanks to Al Viro for noticing that putrootfh could return either a linux or
an nfs error.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:27:19 +0000 (18:27 -0700)]
[PATCH] nfsd: clean up nfsd4_process_open2
Comments, dprintk cleanup
Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:27:05 +0000 (18:27 -0700)]
[PATCH] nfsd4: move some nfsd4_process_open2 code to nfs4_new_open
Move most of the code in the new_open case of nfsd4_process_open2 to
nfs4_new_open.
Signed-off-by: Andy Adamson <andros@umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:26:49 +0000 (18:26 -0700)]
[PATCH] nfsd4: move open_upgrade code into a separate function
Move most of the code for the open_upgrade case into a separate
nfs4_upgrade_open.
Signed-off-by: Andy Adamson <andros@umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:26:38 +0000 (18:26 -0700)]
[PATCH] nfsd4: reorganize "if" in nfsd4_process_open2 to make test clearer
Reorganize "if" in nfsd4_process_open2 to make test clearer; there was no real
reason to test for the negative here.
Signed-off-by: Andy Adamson <andros@umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:26:23 +0000 (18:26 -0700)]
[PATCH] nfsd4: move seqid decrement on reclaim to separate function
Move seqid decrement on reclaim to separate function
Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:26:11 +0000 (18:26 -0700)]
[PATCH] nfsd: set OPEN_RESULT_LOCKTYPE_POSIX in open()
We should set the OPEN_RESULT_LOCKTYPE_POSIX flag in the return to open, to
indicate that we support locking.
Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:25:56 +0000 (18:25 -0700)]
[PATCH] nfsd4: move open owner checks from nfsd4_process_open2 into new function
nfsd4_process_open2 has become a bit long and contorted. The following
patches break nfsd4_process_open2 into smaller functions and add comments to
describe logic flow, in preparation for delegation state.
We begin by pulling out the code that searches for conflicting open owners
into a separate function.
Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:25:41 +0000 (18:25 -0700)]
[PATCH] nfsd: remove incorrect stateid modification in nfsv4 open upgrade
When we upgrade an open, we keep the same stateid and bump only the seqid.
Signed-off-by: Andy Adamson <andros@umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:25:26 +0000 (18:25 -0700)]
[PATCH] nfsd4: fix race in xdr encoding of lock_denied response.
We take a reference on the stateowner, and copy the clientid, instead of just
hoping no one destroys the stateowner before we reference it in
nfsd4_encode_lock_denied.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:25:12 +0000 (18:25 -0700)]
[PATCH] nfsd4: revert awkward extension of state lock over xdr for replay encoding
With the addition of a reference count, we no longer need the code that
conditionally extended the nfs4 state lock over the xdr encode stage.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:24:58 +0000 (18:24 -0700)]
[PATCH] nfsd4: take a reference to preserve stateowner through xdr replay code
Take a reference to preserve the stateowner through the xdr replay code, and
simplify nfsd4_proc_compound a little.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:24:43 +0000 (18:24 -0700)]
[PATCH] nfsd4: reference count stateowners
Reference-counting the nfsd4 stateowner structs will let us fix a race and
simplify some of the xdr code a bit, and may also help us make the nfsd4
locking a little more fine-grained in the future.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:24:28 +0000 (18:24 -0700)]
[PATCH] nfsd: make sure getxattr inode op is non-NULL before calling it
Make sure getxattr inode op is non-NULL before calling it.
Also, security hook should probably be called before calling the getxattr op
the first time.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:24:16 +0000 (18:24 -0700)]
[PATCH] nfsd4: don't take i_sem around call to ->getxattr
The ->getxattr op doesn't take the i_sem (see
Documentation/filesystems/Locking)
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:24:01 +0000 (18:24 -0700)]
[PATCH] nfsd: separate a little of logic from fh_verify into new function
Separate out the little bit of logic in fh_verify that checks the i_mode into
a separate function. This is nicely encapsulated, fh_verify() is overly long
anyway, and this change helps make a subsequent nfs4 named attribute change
clearer.
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Neil Brown [Wed, 20 Oct 2004 01:23:47 +0000 (18:23 -0700)]
[PATCH] nfsd4: nfsd oopsed when encountering a conflict with a local lock
Bug Fix: Non NFSD conflicting byte-range locks were causing an Oops.
Encode a zero length owner and zero clientid for non NFSD conflicting locks in
the lock_denied response.
Signed-off-by: Andy Adamson <andros@umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Neil Brown <neilb@cse.unsw.edu.au> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Martin Schlemmer [Wed, 20 Oct 2004 01:23:20 +0000 (18:23 -0700)]
[PATCH] Select cpio_list or source directory for initramfs image
Attached is a patch that adds CONFIG_INITRAMFS_SOURCE, enabling you to
either specify a file as cpio_list, or a directory to generate a list from.
It depreciate the INITRAMFS_LIST environment variable introduced not long
ago.
There are some issues (suggestions/patches welcome) that I am not
sure about:
1) I put the menu entry under block devices, but I am not sure if
this is the correct location?
2) There might be a better (or more correct) way to do this with
kbuild?
3) Variable names and especially help text needs some love.
4) I am not sure if I am duplicating work in progress?
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Thayne Harbaugh [Wed, 20 Oct 2004 01:23:04 +0000 (18:23 -0700)]
[PATCH] gen_init_cpio uses external file list
This patch makes gen_init_cpio generate the initramfs_data.cpio from a file
which contains a list of entries: file, dir, nod. I swapped the order of
filename/location for the file arguments so that it would be more uniform
with the dir and node tyes.
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Michael Hunold [Wed, 20 Oct 2004 01:22:10 +0000 (18:22 -0700)]
[PATCH] DVB: misc driver updates
- [DVB] av7110: convert MODULE_PARM() to module_param(), replace home-brewn
waiting stuff in osd code with wait_event_interruptible_timeout()
- [DVB] av7110: put a semaphore around osd calls to make sure they're
properly serialized, timeout variable in arm_thread() must be int, not
unsigned long
- [DVB] av7110: add additional OSD window types (patch by Jeremy Jones), new
ioctl OSD_GET_CAPABILITY/OSD_CAP_MEMSIZE; returns size of OSD memory
- [DVB] av7110: put audio/video initialization into separate function
init_av7110_av(); call this function after system initialization and after
arm crash to restore the previous state; thanks to Soeren Sonnenburg
<bugreports@nn7.de> for this patch.
Michael Hunold [Wed, 20 Oct 2004 01:20:58 +0000 (18:20 -0700)]
[PATCH] DVB: frontend conversion #3
- [DVB] dvb_dummy_fe, grundig_29504-401, grundig_29504-491, mt312: convert
from dvb-i2c to kernel-i2c, MODULE_PARM() to module_param(), dvb_delay() to
mdelay()
- [DVB] update frontend Kconfig
Signed-off-by: Michael Hunold <hunold@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Michael Hunold [Wed, 20 Oct 2004 01:20:16 +0000 (18:20 -0700)]
[PATCH] DVB: core update
- [DVB] remove non-linux compatibility stuff from dvb_functions. rest in
peace.
- [DVB] remove home-brewn dvb-i2c stuff. rest in peace.
- [DVB] convert MODULE_PARM() to module_param()
- [DVB] convert dvb_delay() to mdelay()
- [DVB] convert C++ comments to C comments
- [DVB] dvb_ca_en50221: fix for matrix CAMs from Sjoerd Simons, use c99
initializers, Fix for aston CAM read timeout problems, Moved CAM CTRL IF
reset to a better place, better debugging with multiple cards (Sjoerd
Simons)
- [DVB] dvb-frontend: patch by Wolfgang Fritz: suppress spurious events
during tuning, Do not allow write (and related) ioctls when frontend is
opened RDONLY, Properly lock the frontend module on open/close, patch by
Christopher Pascoe: remove bogus up(fe->sem) on fe thread exit, patch by
Christopher Pascoe: remove bogus up(fe->sem) on fe thread exit
- [DVB] dvb-demux: using spin_lock instead of spin_lock_irq caused a race
condition between irq/tasklet and user space task
- [DVB] dvb-core: add sysfs/udev support using "class_simple", prevent Oops
when PES filter is set with invalid pes_type, protect feed_list with
spin_locks
Signed-off-by: Michael Hunold <hunold@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Michael Hunold [Wed, 20 Oct 2004 01:19:59 +0000 (18:19 -0700)]
[PATCH] DVB: skystar2 dvb bt8xx update
- [DVB] convert drivers from dvb-i2c to kernel-i2c
- [DVB] convert MODULE_PARM() to module_param()
- [DVB] convert dvb_delay() to mdelay()
- [DVB] dvb-bt8xx: convert home-brewn bttv i2c access to a real bttv sub-driver
Signed-off-by: Michael Hunold <hunold@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Michael Hunold [Wed, 20 Oct 2004 01:19:44 +0000 (18:19 -0700)]
[PATCH] DVB: documentation update
- [DVB] add udev.txt which describes how to use dvb and udev/sysfs
- [DVB] add Visionplus VisionDTV USB-Ter DVB-T adapter documentation
- [DVB] update TT USB DEC documentation
- [DVB] update various Kconfig entries
- [DVB] remove obsolete firmware documentation
Signed-off-by: Michael Hunold <hunold@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Gerd Knorr [Wed, 20 Oct 2004 01:18:39 +0000 (18:18 -0700)]
[PATCH] DVB/V4L dependency fix
The problem is that dvb is way to much work-in-progress right now, it's
almost impossible to build something which works on both mainline kernel +
latest dvb cvs. Hope at least the interfaces are settled soon, for now I
gave up on getting it work in mainline in short-term.
The patch below compiles the DVB card configuration code only when
VIDEO_CX88_DVB is enabled (which is commented right now in Kconfig due to
being broken).
Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Gerd Knorr [Wed, 20 Oct 2004 01:18:25 +0000 (18:18 -0700)]
[PATCH] v4l: cx88 driver update
This is a major update of the cx88 driver. Main new feature is support
for the MPEG PCI function of the cx2388x chips. The changes in detail:
* A bunch of code restructions, to allow multiple modules (one per PCI
function) work on top of the core module.
* Add a new module with common code for the mpeg PCI function.
* Add a new module to support mpeg encoder cards (connexant
"blackbird" reference design). That one is not much tested yet and
may have bugs. They can be easily workarounded by not loading the
module through, it isn't needed to capture uncompressed video.
* Add a new module to support DVB cards. That one is better tested
than the blackbird one, but it needs additional cutting-edge stuff
from the dvb project, thats why it is disabled in Kconfig for now.
* Several cleanups along the way: use kthread, use msleep(), drop some
2.4.x compatibility code, move insmod options to 2.6 style, ...
* adapt code to the video-buf changes.
* suspend fixes.
* as usual some new tv cards.
Gerd Knorr [Wed, 20 Oct 2004 01:18:09 +0000 (18:18 -0700)]
[PATCH] v4l: bttv driver update
This update for the bttv driver. Changes:
* adapt the driver to video-buf changes.
* It also added sanity checks for the bt878 risc code buffer sizes.
* adds support for new tv cards.
* cleanup i2c driver autoload.
* misc cleanups (msleep, ...).
* fix IRQ bug when stopping vbi capture.
* drop check for cx2388x (bt878 successor) and the printk saying bttv
doesn't support these.
* set i2c class correctly for dvb cards.
Gerd Knorr [Wed, 20 Oct 2004 01:17:42 +0000 (18:17 -0700)]
[PATCH] v4l: avoid using struct file ptrs in video-buf
This patch makes the video-buf helper module pass through a void pointer
instead of a struct file pointer, that makes the code also usable when no
file pointer is available. This is needed for when using the video-buf
infrastructure to manage DMA buffers for DVB cards.
The file pointer was used by the videobuf_queue_ops callbacks to get the
drivers private data via file->private_data, now a pointer to the drivers's
private data can be passed directly.
Adaptions of the drivers follow with separate patches.
Hugh Dickins [Wed, 20 Oct 2004 01:17:12 +0000 (18:17 -0700)]
[PATCH] lighten mmlist_lock
Let's lighten the global spinlock mmlist_lock.
What's it for?
1. Its original role is to guard mmlist.
2. It later got a second role, to prevent get_task_mm from raising
mm_users from the dead, just after it went down to 0.
Firstly consider the second: __exit_mm sets tsk->mm NULL while holding
task_lock before calling mmput; so mmlist_lock only guards against the
exceptional case, of get_task_mm on a kernel workthread which did AIO's
use_mm (which transiently sets its tsk->mm without raising mm_users) on an
mm now exiting.
Well, I don't think get_task_mm should succeed at all on use_mm tasks.
It's mainly used by /proc/pid and ptrace, seems at best confusing for those
to present the kernel thread as having a user mm, which it won't have a
moment later. Define PF_BORROWED_MM, set in use_mm, clear in unuse_mm
(though we could just leave it), get_task_mm give NULL if set.
Secondly consider the first: and what's mmlist for?
1. Its original role was for swap_out to scan: rmap ended that in 2.5.27.
2. In 2.4.10 it got a second role, for try_to_unuse to scan for swapoff.
So, make mmlist a list of mms which maybe have pages on swap: add mm to
mmlist when first swap entry is assigned in try_to_unmap_one (pageout), or
in copy_page_range (fork); and mmput remove it from mmlist as before,
except usually list_empty and there's no need to lock. drain_mmlist added
to swapoff, to empty out the mmlist if no swap is then in use.
mmput leave mm on mmlist until after its exit_mmap, so try_to_unmap_one can
still add mm to mmlist without worrying about the mm_users 0 case; but
try_to_unuse must avoid the mm_users 0 case (when an mm might be removed
from mmlist, and freed, while it's down in unuse_process): use
atomic_inc_return now all architectures support that.
Some of the detailed comments in try_to_unuse have grown out of date:
updated and trimmed some, but leave SWAP_MAP_MAX for another occasion.
Hirofumi Ogawa [Wed, 20 Oct 2004 01:16:56 +0000 (18:16 -0700)]
[PATCH] FAT: remove validity check of FAT first entry
The low byte of FAT's first entry must have same value with media-field.
So, I added that validity check for some case. In fact, in some case
this check detected non-FAT filesystem. But in real world,
unfortunately too many devices is writing a wrong value.