Commit Graph

1121 Commits

Author SHA1 Message Date
Takashi Iwai
38223daa1a [ALSA] cs4281 - Fix the check of timeout in probe
Fix the check of timeout in probe routines to work properly
reagrdless of HZ (ALSA bug#1976).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:59:00 +02:00
Takashi Iwai
e860f00047 [ALSA] cs4281 - Fix the check of right channel
Fix the check of right channel in mixer volume put callback.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:59:00 +02:00
Takashi Iwai
14790f1c73 [ALSA] Test volume resolution of usb audio at initialization
Test the volume of usb audio whether actually it works and adjusts
the resolution value according to it.

Some USB audio devices report a lower resolution than it reacts.
The only possible check is to write and read a volume value.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:59:00 +02:00
Andreas Mohr
0b2dcd5d6a [ALSA] maestro3.c: fix BUG, optimization
- fix brown-paper-bag locking bug (lock() / return / unlock())
- improve central function snd_m3_update_ptr()
  (avoid expensive integer divisions)
- add cpu_relax() to busy-wait I/O loop as recommended
  (does this require special macro support in ALSA for older kernels??)
- constify several structs
- spelling updates

Signed-off-by: Andreas Mohr <andi@lisas.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:59:00 +02:00
Jonathan Woithe
a1e8d2da03 [ALSA] HDA/Realtek: multiple input mux definitions and pin mode additions
The following patch relative to CVS from 20060324 adds the following
features to the Realtek HDA codec.

1) Define two new pin modes: ALC_PIN_DIR_IN_NOMICBIAS and
   ALC_PIN_DIR_INOUT_NOMICBIAS.  These can be used with jack mode switch
   definitions in mixers to prevent the user being offered the mic bias
   options if the hardware doesn't support it.

2) Add the ability to have different input mux definitions for different
   ADCs.  This is needed because the ALC260 chip uses different mux layouts
   for the two onboard ADCs.  A new field (num_mux_defs) was added to the
   alc_spec and alc_config_preset structures to support this.

3) Adjust numerous comments to make them consistent with the above changes.

4) Utilise the new multi-mux definition functionality for the ALC260 fujitsu
   model to allow recording of the mixer output.

5) Utilise the new multi-mux definition functionality for the ALC260 test
   model to make the mux selections a little less confusing.

6) Allow the headphone jack of the ALC260 acer model to be retasked in
   the mixer.

6) Utilise the new multi-mux definition functionality for the ALC260 acer
   model to give access to the mixer output and the retasked headphone
   jack.

At this stage the *_NOMICBIAS modes are not used.  We have reports that the
"Line" jack of at least some Acer models doesn't pass the bias out, and we
also know that NIDs 0x0f and 0x10 don't seem to accept the mic bias requests
at all.  However, I feel we need to collect more evidence on both counts
before committing to the use of *_NOMICBIAS.  In the case of the Acers, it's
not clear whether this issue (probably caused by the inclusion of DC
blocking capacitors) affects all Acer models or just a small number.  With
the issue with NIDs 0x0f and 0x10 it's unclear whether this is a hardware
bug which will be addressed in later chip revisions or if it's an
intentional restriction.  The datasheet makes no mention of the restriction
so at this stage I'm inclined to consider it a hardware bug.  Comments in
the source reflect this reasoning.

On a similar theme, the headphone jack of the Fujitsu S7020 also doesn't
appear to pass mic bias voltage.  I'm still investigating this however.

With the ability to retask the headphone jack, owners of ALC260-based Acer
laptops should now be able to record 4 channels of audio if they desire. The
multiple mux definitions allow this jack to be presented from both ADCs
(since this mux input is one of those which differs between the muxes).

This patch has been tested on a Fujitsu S7020 laptop and appears to behave
itself both for the "test" and "fujitsu" models.  Definitions using only a
single mux specification also work.  Other ALC chips should be fine but I
cannot test these myself.  The "auto" modes should also continue to function
but again I have not verified this.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:59:00 +02:00
Rene Herman
cf40a310a7 [ALSA] AdLib FM card driver
Attached you'll find an ALSA driver for AdLib FM cards. An AdLib card is
just an OPL2, which was already supported by sound/drivers/opl3, so only
very minimal bus-glue is needed. The patch applies cleanly to both
2.6.16 and 2.6.16-mm1.

The driver has been tested with an actual ancient 8-bit ISA AdLib card
and works fine. It also works fine for an OPL3 {,emulation} as still
found on many ISA soundcards but given that AdLib cards don't have their
own mixer, upping the volume from 0 might be a problem without the card
driver already loaded and driving the OPL3.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:59 +02:00
Takashi Iwai
060d77b9c0 [ALSA] Fix / clean up PCM-OSS setup hooks
- Fix possible race of referring the setup hook from the running PCM
- Fix memory leak in an error path of proc write
- Clean up the setup hook parser

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:59 +02:00
Takashi Iwai
3bf75f9b90 [ALSA] Clean up PCM codes (take 2)
- Clean up initialization and destruction of substream instance
  Now snd_pcm_open_substream() alone does most initialization jobs.
  Add pcm_release callback for cleaning up at snd_pcm_release_substream()
- Tidy up PCM oss code

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:59 +02:00
Takashi Iwai
bf1bbb5a49 [ALSA] Tiny clean up of PCM codes
- Make snd_pcm_prepare() static
- Clean up snd_pcm_kernel_*_ioctl() functions, reduce exports

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:58 +02:00
Rene Herman
82756b2785 [ALSA] ISA drivers bailing on first !enable[i]
Fix the wrong check of enable option in cmi8330 driver.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:58 +02:00
Takashi Iwai
43560116d1 [ALSA] Remove obsolete kfree_nocheck call
Fixed the compilation, removing obsolete kfree_nocheck() call
for memory debugging.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:58 +02:00
Takashi Iwai
10d150e186 [ALSA] Remove obsolete kfree_nocheck call
Fixed the compilation, removing obsolete kfree_nocheck() call
for memory debugging.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:58 +02:00
Ash Willis
b3a70d5ece [ALSA] Add snd-als300 driver for Avance Logic ALS300/ALS300+ soundcards
Added snd-als300 driver for Avance Logic ALS300/ALS300+ soundcards
by Ash Willis.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:58 +02:00
Peter Gruber
109a9638f0 [ALSA] Add snd-riptide driver for Conexant Riptide chip
Add snd-riptide driver for Conexant Riptide chip by Peter Gruber.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:57 +02:00
Takashi Iwai
2125cad291 [ALSA] hda-codec - Fix noisy output wtih AD1986A 3stack model
Fixed the noisy output wtih AD1986A 3stack model using 2 channels.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:57 +02:00
Takashi Iwai
505cb341ef [ALSA] hda-codec - Fix unsol event initialization at resume of stac92xx
Fix the re-initialization of unsolicited events at resume of stac92xx codecs.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:57 +02:00
Takashi Iwai
675b4e5981 [ALSA] Make CONFIG_SND_CS46XX_NEW_DSP yes as default
Removed from CONFIG_EXPERIMENTAL from CONFIG_SND_CS46XX_NEW_DSP, and
make default to yes.  This option works fine for years.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:57 +02:00
Martin Langer
1841f613fd [ALSA] Add snd-miro driver
Added snd-miro driver for miroSOUND PCM by Martin Langer.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:56 +02:00
Takashi Iwai
cbac4b0cb6 [ALSA] Cleanup unused argument for snd_power_wait()
Removed the unused file argument of snd_power_wait().

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:56 +02:00
Alan Horstmann
6285ae1df1 [ALSA] ice1712 - Fix wrong register value for DMX 6FIRE
I have just discovered I made an error in the register value set in 'Limit
dmx6fire to 6 dacs' patch (bug1472).  The value set should be '2a' not '0a'
as in the original patch, which unintentionally disables the 2nd MPU 401
UART.

Signed-off-by: Alan Horstmann <gineera@aspect135.co.uk>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:56 +02:00
Takashi Iwai
c04d092bde [ALSA] via82xx - Add dxs entry for EPoX EP-8KRAI
Added the dxs_support entry for EPoX EP-8KRAI (ALSA bug#1423).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:56 +02:00
Takashi Iwai
c960a03bee [ALSA] hda-codec - Fix VREF level of Mic inputs on STAC92xx codecs
Fixed VREF level of Mic inputs on STAC92xx codecs (ALSA bug#1953).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:56 +02:00
Takashi Iwai
d681518a56 [ALSA] Add support of LG LW20 laptop
Add support of LG LW20 laptop with ALC880 codec (ALSA bug#1572).

Signed-off-by: Takashi Iwai <tiwai@suse.de>
2006-03-31 17:58:55 +02:00
Paul Mackerras
bac30d1a78 Merge ../linux-2.6 2006-03-29 13:24:50 +11:00
Jesper Juhl
4fa95ef639 [PATCH] sound: Remove unneeded kmalloc() return value casts
Get rid of unnessesary casts of kmalloc() return value in sound/

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Cc: Jaroslav Kysela <perex@perex.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:09 -08:00
Alexey Dobriyan
7f927fcc2f [PATCH] Typo fixes
Fix a lot of typos.  Eyeballed by jmc@ in OpenBSD.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:08 -08:00
Jesper Juhl
ca43b317fc [PATCH] vfree does its own NULL check, no need to be explicit in oss/msnd.c
vfree() does it's own NULL checking, no need for explicit check before
calling it.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:08 -08:00
Jesper Juhl
5a83fdddb8 [PATCH] no need to check vfree arg for null in oss/sequencer
There's no need to check pointers for NULL before handing them to vfree().

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:08 -08:00
Jesper Juhl
07e0e93d9a [PATCH] maestro3 vfree NULL check fixup
vfree() checks for NULL, no need to do it explicitly.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Acked-by: Zach Brown <zab@zabbo.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:08 -08:00
Jesper Juhl
457d3d432b [PATCH] vfree NULL check fixup for sb_card
There's no need to check the vfree() argument for NULL.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:07 -08:00
Matthias Gehre
910638ae7e [PATCH] Replace 0xff.. with correct DMA_xBIT_MASK
Replace all occurences of 0xff..  in calls to function pci_set_dma_mask()
and pci_set_consistant_dma_mask() with the corresponding DMA_xBIT_MASK from
linux/dma-mapping.h.

Signed-off-by: Matthias Gehre <M.Gehre@gmx.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:07 -08:00
Arjan van de Ven
99ac48f54a [PATCH] mark f_ops const in the inode
Mark the f_ops members of inodes as const, as well as fix the
ripple-through this causes by places that copy this f_ops and then "do
stuff" with it.

Signed-off-by: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-28 09:16:05 -08:00
Benjamin Herrenschmidt
e8222502ee [PATCH] powerpc: Kill _machine and hard-coded platform numbers
This removes statically assigned platform numbers and reworks the
powerpc platform probe code to use a better mechanism.  With this,
board support files can simply declare a new machine type with a
macro, and implement a probe() function that uses the flattened
device-tree to detect if they apply for a given machine.

We now have a machine_is() macro that replaces the comparisons of
_machine with the various PLATFORM_* constants.  This commit also
changes various drivers to use the new macro instead of looking at
_machine.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-03-28 23:15:54 +11:00
Bjorn Helgaas
c94ded6e60 [PATCH] PNP: adjust pnp_register_card_driver() signature: wavefront
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:55 -08:00
Bjorn Helgaas
3812595644 [PATCH] PNP: adjust pnp_register_card_driver() signature: sscape
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
be54414d59 [PATCH] PNP: adjust pnp_register_card_driver() signature: sb_card
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
312fef308c [PATCH] PNP: adjust pnp_register_card_driver() signature: sb16
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
ebdb71ea7b [PATCH] PNP: adjust pnp_register_card_driver() signature: interwave
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
6a3a3a0260 [PATCH] PNP: adjust pnp_register_card_driver() signature: es968
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
fea9739f2a [PATCH] PNP: adjust pnp_register_card_driver() signature: es18xx
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
6736a6587b [PATCH] PNP: adjust pnp_register_card_driver() signature: dt019x
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
07d58ad06b [PATCH] PNP: adjust pnp_register_card_driver() signature: cmi8330
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix some __init/__devinit issues.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:54 -08:00
Bjorn Helgaas
db2735eb90 [PATCH] PNP: adjust pnp_register_card_driver() signature: azt2320
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
51427ec0f2 [PATCH] PNP: adjust pnp_register_card_driver() signature: als100
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.  And fix a __init/__devinit issue.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
5f53f4e210 [PATCH] PNP: adjust pnp_register_card_driver() signature: ad1816a
Remove the assumption that pnp_register_card_driver() returns the
number of devices claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Cc: Jaroslav Kysela <perex@suse.cz>
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
070c699983 [PATCH] pnp: cs4232: adjust pnp_register_driver signature
Remove the assumption that pnp_register_driver() returns the number of devices
claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
8c59c4a221 [PATCH] pnp: opl3sa2: adjust pnp_register_driver signature
Remove the assumption that pnp_register_driver() returns the number of devices
claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
ed7cb19131 [PATCH] pnp: cs4236: adjust pnp_register_driver signature
Remove the assumption that pnp_register_driver() returns the number of devices
claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Bjorn Helgaas
f301ae6a69 [PATCH] pnp: mpu401: adjust pnp_register_driver signature
This series of patches removes the assumption that pnp_register_driver()
returns the number of devices claimed.  Returning the count is unreliable
because devices may be hot-plugged in the future.  (Many devices don't support
hot-plug, of course, but PNP in general does.)

This changes the convention to "zero for success, or a negative error value,"
which matches pci_register_driver(), acpi_bus_register_driver(), and
platform_driver_register().

If drivers need to know the number of devices, they can count calls to their
.probe() methods.

This patch:

Remove the assumption that pnp_register_driver() returns the number of devices
claimed.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Adam Belay <ambx1@neo.rr.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-27 08:44:53 -08:00
Richard Knutsson
20548664aa [PATCH] oss/sonicvibes.c defines its own hweight32
sound/oss/sonicvibes.c:421: error: static declaration of hweight32 follows non-static declaration
include/asm-generic/bitops/hweight.h:6: error: previous declaration of hweight32 was here

Signed-off-by: Richard Knutsson <ricknu-0@student.ltu.se>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-03-26 08:57:09 -08:00