- 08 Jun, 2004 3 commits
-
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Russell King authored
This patch adds management of platform device resources to the device model, allowing drivers to lookup resources, IRQs and DMA numbers in the platform device resource array. We also add a couple of functions which allow platform devices and their resources to be registered. Signed-off-by: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Hanna V. Linder authored
Here is the patch that uses a cpu hotplug callback, to allow dynamic support of cpu id for classes in sysfs. This patch applies on top of the one I sent out earlier that Greg included. I do not have access to hardware that supports cpu hotswapping (virtually or not) so have not been able to test that aspect of the patch. However, the original functionality of listing static cpu's still works. Please consider for testing or inclusion. Signed-off-by: Hanna Linder <hannal@us.ibm.com> Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
- 04 Jun, 2004 5 commits
-
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Jonathan Corbet authored
So here I am trying to write about how one can apply gdb to a running kernel, and I'd like to tell people how to debug loadable modules. Only with the 2.6 module loader, there's no way to find out where the various sections in the module image ended up, so you can't do much. This patch attempts to fix that by adding a "sections" subdirectory to every module's entry in /sys/module; each attribute in that directory associates a beginning address with the section name. Those attributes can be used by a a simple script to generate an add-symbol-file command for gdb, something like: #!/bin/bash # # gdbline module image # # Outputs an add-symbol-file line suitable for pasting into gdb to examine # a loaded module. # cd /sys/module/$1/sections echo -n add-symbol-file $2 `/bin/cat .text` for section in .[a-z]* *; do if [ $section != ".text" ]; then echo " \\" echo -n " -s" $section `/bin/cat $section` fi done echo Currently, this feature is absent if CONFIG_KALLSYMS is not set. I do wonder if CONFIG_DEBUG_INFO might not be a better choice, now that I think about it. Section names are unmunged, so "ls -a" is needed to see most of them. Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Frank A. Uepping authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com> On Saturday 27 March 2004 02:14, Greg KH wrote: > On Sat, Mar 06, 2004 at 12:47:24PM +0100, Frank A. Uepping wrote: > > Hi, > > if device_add fails (e.g. bus_add_device returns an error) then the release > > method will be called for the device. Is this a bug or a feature? > > Are you sure this will happen? device_initialize() gets a reference > that is still present after device_add() fails, right? So release() > will not get called. At the label PMError, kobject_unregister is called, which decrements the recount by 2, which will result in calling release at label Done (put_device). kobject_unregister should be superseded by kobject_del. Here is a patch:
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
- 03 Jun, 2004 32 commits
-
-
bk://kernel.bkbits.net//home/mochel/linux-2.6-coreGreg Kroah-Hartman authored
into kroah.com:/home/greg/linux/BK/driver-2.6
-
Patrick Mochel authored
- Add struct bus_type::dev_attrs, which is an array of device attributes that are added to each device as they are registered. - Also make sure that we don't hang when removing bus attributes if adding one failed..
-
Patrick Mochel authored
- Similar to default attributes for struct class, this is an array of attributes, terminated with an attribute with a NULL name, that are added when the bus is registered, and removed when the bus is unregistered.
-
Hanna V. Linder authored
This patch adds class support to arch/i386/kernel/cpuid.c. This enables udev support. I have tested on a 2-way SMP system and on a 2-way built as UP. Here are the results for the SMP: [hlinder@w-hlinder2 hlinder]$ tree /sys/class/cpuid /sys/class/cpuid |-- cpu0 | `-- dev `-- cpu1 `-- dev 2 directories, 2 files [hlinder@w-hlinder2 hlinder]$ more /sys/class/cpuid/cpu0/dev 203:0 [hlinder@w-hlinder2 hlinder]$ more /sys/class/cpuid/cpu1/dev 203:1 [hlinder@w-hlinder2 hlinder]$ And for the UP: [root@w-hlinder2 root]# tree /sys/class/cpuid /sys/class/cpuid `-- cpu0 `-- dev 1 directory, 1 file Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Greg Kroah-Hartman authored
Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Patrick Mochel authored
- add struct class::class_attrs, which is designed to point to an array of class_attributes that are added when the class is registered and removed when the class is unregistered. This allows for more consolidated and cleaner definition of and management of attributes. - Add struct class::class_dev_attrs to do something similarly for class devices. Each class device that is registered with the class gets that set of attributes added for them, and subsequently removed when the device is unregistered. Each array depends on a terminating attribute with a NULL name. Hint: use the new __ATTR_NULL macro to terminate it.
-
Patrick Mochel authored
- Returns the name of an embedded attribute in a higher-level attribute.
-
Greg Kroah-Hartman authored
This is needed by people who use udev and want raw devices. SuSE is shipping with this patch. Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
bk://kernel.bkbits.net/mochel/linux-2.6-coreGreg Kroah-Hartman authored
into kroah.com:/home/greg/linux/BK/driver-2.6
-
Patrick Mochel authored
- Hey, just because the macro incorrectly included a ';' doesn't mean one shouldn't add one on their own.. (Or at least be consistent.) Signed-off-by: Greg Kroah-Hartman <greg@kroah.com>
-
Russell King authored
swapper_space is needed by at least loop/st/sg these days.
-
Paul Mackerras authored
The last patch I sent means that we have WARN_ON(0) in a couple of places when CONFIG_PREEMPT=n. This patch makes that reduce to nothing (rather than a conditional trap on a 0 value), and also makes BUG_ON(0) reduce to nothing for completeness. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
Ben H added a check in a couple of places to make sure that we had preemption disabled when we call enable_kernel_{fp,altivec}. Unfortunately the check he used trips in the case when CONFIG_PREEMPT=n. This patch fixes it by defining a preemptible() macro (which reduces to 0 when CONFIG_PREEMPT=n) and doing WARN_ON(preemptible()). Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
The main thrust of this patch is to make the ppc32 PCI code more robust by checking for bus->resource[] being NULL before using it. We can legitimately get elements of bus->resource being NULL and I have actually hit that on some machines. This patch also allows resources starting at 0 to be accepted as assigned (we can and do get PCI resources starting at 0 in I/O space on PPC machines) and provides a sensible default for the case where Open Firmware doesn't give us a bus-range property for a PCI bridge. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
The ppc32 boot code has a couple of files that are executed very early on before the kernel is mapped at the address it is linked at. We have been using -mrelocatable-lib to compile these files, but apparently -mrelocatable-lib is deprecated and the gcc developers are threatening to remove it. In fact the -fPIC flag does what we need. This patch changes -mrelocatable-lib to -fPIC. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
In the ppc32 kernel, we have a /proc/ppc_htab file that trawls through the MMU hash table and prints various statistics on it such as percent occupancy. However, the hash table entry format is different on 64-bit cpus (POWER3, G5) which the ppc32 kernel does support (in 32-bit mode). This patch disables the scanning of the MMU hash table and printing of the statistics that we get from it on 64-bit cpus. Since the statistics are only for interest, and the ppc32 kernel is being used less and less on 64-bit cpus now that the ppc64 kernel is in reasonable shape, I didn't think it worth while to add code to deal with the 64-bit HPTE format. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
This patch is the ppc32 counterpart to a fix that went into arch/i386/kernel/irq.c last October. The bug was noted by Al Viro: if no handler exists, and we have IRQ_INPROGRESS set because of an earlier irq that got through, synchronize_irq() will end up waiting forever. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Paul Mackerras authored
I tried compiling a PPC32 kernel with PREEMPT + SMP and it failed because we didn't have a _raw_write_trylock. This patch adds _raw_write_trylock, moves the exports of _raw_*lock from arch/ppc/kernel/ppc_ksyms.c to arch/ppc/lib/locks.c, and makes __spin_trylock static since it is only used in locks.c. Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Linus Torvalds authored
-
Andrew Morton authored
clean_blockdev_aliases() is using the wrong thing to work out how many filesystem blocks should be invalidated. It invalidates too many, which can cause live fs metadata buffers to be invalidated when they are pending writeout. It's a filesystem-wrecker, although seems very hard to hit. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Jerzy Szczepkowski <js189202@zodiac.mimuw.edu.pl> There is a bug in sys_io_setup(). If ioctx_alloc() succeeds and put_user() fails io_destroy() is called. io_destroy() assumes that ioctx->users >= 2 (if context is alive) and calls put_ioctx twice, while in this sequence ioctx->users == 1. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: "Patrick J. LoPresti" <patl@users.sourceforge.net> This patch changes default_cylinders, default_heads, default_sectors_per_track, legacy_max_cylinder, legacy_max_head, legacy_sectors_per_track, and sectors to decimal. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: "Patrick J. LoPresti" <patl@users.sourceforge.net> Renames legacy_heads to legacy_max_head legacy_sectors to legacy_sectors_per_track. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Nathan Lynch <nathanl@austin.ibm.com> The hotcpu_notifier macro does not properly record the given priority in the notifier block. This causes trouble only for callers which specify a non-zero priority, of which there are none (yet). Signed-off-by: Nathan Lynch <nathanl@austin.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Jeff Mahoney <jeffm@suse.com> Chris Mason and I ran across this one while hunting down another bug. If ext3_mark_iloc_dirty() fails in ext3_orphan_del() on the outer buffer, bh->b_count will be decremented twice. ext3_mark_iloc_dirty() will brelse the buffer, even on error. ext3_orphan_del() is explicity brelse'ing the buffer on error. Prior to calling ext3_mark_iloc_dirty(), this is the correct behavior. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Matt Tolentino <metolent@snoqualmie.dp.intel.com> The elilo EFI boot loader has been moved to sourceforge. So, update the location of where one might look for it. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Matt Tolentino <metolent@snoqualmie.dp.intel.com> The /proc support for efi 'stuff' isn't used/needed anymore, yet the efi_dir declaration remains. This removes it. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Jan Kara <jack@ucw.cz> Fix a problem in the old quota format when we tried to read quota information after the end of quota file (that is correct as it might a user with sufficiently large UID which has no limits or usage). Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Jan Kara <jack@ucw.cz> Fixes a problem with some quota operations not writing the quota info they changed which could later cause that some transaction to use more buffers than it had reserved or it could cause corrupted quota files when the system was rebooted at the right time. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Martin Schwidefsky <schwidefsky@de.ibm.com> Network driver changes: - iucv: Fix special case of a "Connection Pending" interrupt within iucv_do_int. - netiucv: Revoke broken iucvMagic change for more than one connection. - qeth: Fix string parsing in notifier_register attribute function. - qeth: Add code for socket ioctl SIOC_QETH_GET_CARD_TYPE. - qeth: Fix debug log entry and buffer copy in qeth_snmp_command_cb. - qeth: Fix race on qeth_dbf_txt_buf. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-
Andrew Morton authored
From: Martin Schwidefsky <schwidefsky@de.ibm.com> block device driver changes: - dasd: Fix diag discipline if it is loaded as a module. - dcssblk: Replace r/w lock with r/w semaphore to be able to call device_register inside a critical section. - dcssblk: Fix error handling in write function for dcss "add" attribute. - xpram & dcssblk: Fix sanity check for sector number. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-