History log of /linux-master/sound/isa/ad1816a/ad1816a.c
Revision Date Author Comments
# d6fb54e8 15-Jul-2021 Takashi Iwai <tiwai@suse.de>

ALSA: ad1816a: Allocate resources with device-managed APIs

This patch converts the resource management in ISA ad1816a driver with
devres as a clean up. Each manual resource management is converted
with the corresponding devres helper, and the card object release is
managed now via card->private_free instead of a lowlevel snd_device.

This should give no user-visible functional changes.

Link: https://lore.kernel.org/r/20210715075941.23332-53-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 5ab6d660 08-Jun-2021 Takashi Iwai <tiwai@suse.de>

ALSA: ad1816a: Fix assignment in if condition

ISA AD1816A driver code contains lots of assignments in if condition,
which is a bad coding style that may confuse readers and occasionally
lead to bugs.

This patch is merely for coding-style fixes, no functional changes.

Link: https://lore.kernel.org/r/20210608140540.17885-6-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 6417f031 16-Mar-2021 Leon Romanovsky <leon@kernel.org>

module: remove never implemented MODULE_SUPPORTED_DEVICE

MODULE_SUPPORTED_DEVICE was added in pre-git era and never was
implemented. We can safely remove it, because the kernel has grown
to have many more reliable mechanisms to determine if device is
supported or not.

Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>


# aa08ff0f 15-Apr-2020 Geert Uytterhoeven <geert+renesas@glider.be>

ALSA: Fix misspellings of "Analog Devices"

According to https://www.analog.com/, the company name is spelled
"Analog Devices".

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/20200416103058.15269-6-geert+renesas@glider.be
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 1a59d1b8 27-May-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 156

Based on 1 normalized pattern(s):

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation either version 2 of the license or at
your option any later version this program is distributed in the
hope that it will be useful but without any warranty without even
the implied warranty of merchantability or fitness for a particular
purpose see the gnu general public license for more details you
should have received a copy of the gnu general public license along
with this program if not write to the free software foundation inc
59 temple place suite 330 boston ma 02111 1307 usa

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-or-later

has been chosen to replace the boilerplate/reference in 1334 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Allison Randal <allison@lohutok.net>
Reviewed-by: Richard Fontana <rfontana@redhat.com>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190527070033.113240726@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 287b546c 17-Aug-2017 Arvind Yadav <arvind.yadav.cs@gmail.com>

ALSA: ad1816a: constify pnp_card_device_id

pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 7f605418 01-Jan-2015 Lars-Peter Clausen <lars@metafoo.de>

ALSA: ad1816a: Remove always NULL parameters

snd_ad1816a_pcm() and snd_ad1816a_timer() take a pointer to a pointer of a
PCM/timer where if this parameter is provided the newly allocated object is
stored. All callers pass NULL though, so remove the parameter. This makes
the code a bit cleaner and shorter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 4323cc4d 29-Jan-2014 Takashi Iwai <tiwai@suse.de>

ALSA: isa: Convert to snd_card_new() with a device pointer

Also remove superfluous snd_card_set_dev() calls.

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 1bff292e 05-Dec-2012 Bill Pemberton <wfp5p@virginia.edu>

ALSA: isa: remove __dev* attributes

CONFIG_HOTPLUG is going away as an option. As result the __dev*
markings will be going away.

Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst,
and __devexit.

Signed-off-by: Bill Pemberton <wfp5p@virginia.edu>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 6f0fa660 19-Aug-2012 Ondrej Zary <linux@rainbow-software.org>

ALSA: snd-ad1816a: Implement suspend/resume

Implement suspend/resume support for AD1816 chips.
Tested with Terratec SoundSystem Base-1.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# c86b6b45 19-Aug-2012 Ondrej Zary <linux@rainbow-software.org>

ALSA: snd-ad1816a: remove useless struct snd_card_ad1816a

struct snd_card_ad1816a is only set but the values are never used then.
Removing it allows struct snd_card's private_data to be used for
struct snd_ad1816a, simplifying the code.

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# a67ff6a5 14-Dec-2011 Rusty Russell <rusty@rustcorp.com.au>

ALSA: module_param: make bool parameters really bool

module_param(bool) used to counter-intuitively take an int. In
fddd5201 (mid-2009) we allowed bool or int/unsigned int using a messy
trick.

It's time to remove the int/unsigned int option. For this version
it'll simply give a warning, but it'll break next kernel version.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 65a77217 15-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com>

sound: fix drivers needing module.h not moduleparam.h

The implicit presence of module.h lured several users into
incorrectly thinking that they only needed/used modparam.h
but once we clean up the module.h presence, these will show
up as build failures, so fix 'em now.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>


# dba8b469 13-Sep-2011 Clemens Ladisch <clemens@ladisch.de>

ALSA: mpu401: clean up interrupt specification

The semantics of snd_mpu401_uart_new()'s interrupt parameters are
somewhat counterintuitive: To prevent the function from allocating its
own interrupt, either the irq number must be invalid, or the irq_flags
parameter must be zero. At the same time, the irq parameter being
invalid specifies that the mpu401 code has to work without an interrupt
allocated by the caller. This implies that, if there is an interrupt
and it is allocated by the caller, the irq parameter must be set to
a valid-looking number which then isn't actually used.

With the removal of IRQF_DISABLED, zero becomes a valid irq_flags value,
which forces us to handle the parameters differently.

This patch introduces a new flag MPU401_INFO_IRQ_HOOK for when the
device interrupt is handled by the caller, and makes the allocation of
the interrupt to depend only on the irq parameter. As suggested by
Takashi, the irq_flags parameter was dropped because, when used, it had
the constant value IRQF_DISABLED.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 9fe856e4 04-Sep-2010 Joe Perches <joe@perches.com>

sound: Remove unnecessary casts of private_data

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# a17ac45a 21-Jan-2009 Krzysztof Helt <krzysztof.h1@wp.pl>

ALSA: ad1816a: enable hardware timer

Enable hardware timer with 10 usec resolution.

Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# aa9c293a 21-Jan-2009 Krzysztof Helt <krzysztof.h1@wp.pl>

ALSA: do not create OPL3 timers if there is no OPL3 irq wired

Most cards have OPL3 FM synthetiser but
they do not have OPL3 interrupt wired to
a sound chip or CPU.

Do not create OPL3 timers for such cards
as the timers are useless witthout interrupt.

This patch removes OPL3 timers for following
alsa drivers: snd-ad1816a, snd-opti93x,
snd-opti92x, snd-sc6000, snd-cmi8330.

Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# c95eadd2 28-Dec-2008 Takashi Iwai <tiwai@alsa3.local>

ALSA: Convert to snd_card_create() in sound/isa/*

Convert from snd_card_new() to the new snd_card_create() function.

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 36463a96 21-Aug-2008 Rene Herman <rene.herman@gmail.com>

ALSA: snd-ad1816a: add different TerraTec EWS64 S model

Signed-off-by: Rene Herman <rene.herman@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>


# 9004acc7 08-Jan-2008 Takashi Iwai <tiwai@suse.de>

[ALSA] Remove sound/driver.h

This header file exists only for some hacks to adapt alsa-driver
tree. It's useless for building in the kernel. Let's move a few
lines in it to sound/core.h and remove it.
With this patch, sound/driver.h isn't removed but has just a single
compile warning to include it. This should be really killed in
future.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>


# 109c53f84 30-Nov-2007 Rene Herman <rene.herman@gmail.com>

[ALSA] sound/isa: kill pnp_resource_change

This removes the pnp_resource_change use from the ALSA ISAPnP drivers. In
2.4 these were useful in providing an easy path to setting the resources,
but in 2.6 they retain function as a layering violation only.
This makes for a nice cleanup (-550 lines) of ALSA but moreover, ALSA is the
only remaining user of pnp_init_resource_table(), pnp_resource_change() and
pnp_manual_config_dev() (and, in fact, of 'struct pnp_resource_table') in
the tree outide of drivers/pnp itself meaning it makes for more cleanup
potential inside the PnP layer.
Thomas Renninger acked their removal from that side, you did from the ALSA
side (CC list just copied from that thread).
Against current alsa-kernel HG. Many more potential cleanups in there, but
this _only_ removes the pnp_resource_change code. Compile tested against
current alsa-kernel HG and compile- and use-tested against 2.6.23.x (few
offsets).
Cc: Thomas Renninger <trenn@suse.de>

Signed-off-by: Rene Herman <rene.herman@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>


# 2944275b 19-Mar-2007 Rask Ingemann Lambertsen <rask@sygehus.dk>

[ALSA] ad1816a: Fix modprobe snd_mpu401 && modprobe snd_ad1816a

The ad1816a driver fails if the mpu401 driver has been loaded first. This
patch against linux 2.6.20 fixes it by just ignoring the MPU-401 device in
that case, so that the rest of the sound card can be used. The ad1816a
driver already handles the MPU-401 device being unavailable due to lack of
resources in the same way.

Signed-off-by: Rask Ingemann Lambertsen <rask@sygehus.dk>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>


# b1e8a791 09-Oct-2006 Amit Choudhary <amit2030@gmail.com>

[ALSA] sound/isa/ad1816a/ad1816a.c: check kmalloc() return value

Check the return value of kmalloc() in function snd_card_ad1816a_pnp(),
in file sound/isa/ad1816a/ad1816a.c.

Signed-off-by: Amit Choudhary <amit2030@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>


# 65ca68b3 01-Jul-2006 Thomas Gleixner <tglx@linutronix.de>

[PATCH] irq-flags: sound: Use the new IRQF_ constants

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Jaroslav Kysela <perex@suse.cz>
Cc: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>


# 5f53f4e2 27-Mar-2006 Bjorn Helgaas <bjorn.helgaas@hp.com>

[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>


# 175cdcfb 17-Nov-2005 Takashi Iwai <tiwai@suse.de>

[ALSA] ad1816a - Clean up PnP code

Modules: AD1816A driver

Clean up PnP code of ad1816a driver.

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# cbdd0dd1 17-Nov-2005 Takashi Iwai <tiwai@suse.de>

[ALSA] Remove xxx_t typedefs: ISA AD1816A

Modules: AD1816A driver

Remove xxx_t typedefs from the ISA AD1816A driver.

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 5b8f7f73 03-Aug-2005 Takashi Iwai <tiwai@suse.de>

[ALSA] ad1816a - Add clockfreq module option

Documentation,AD1816A driver
Added clockfreq module option for the card with a different clock frequency
than 33kHz.

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 92bb010c 15-May-2005 Takashi Iwai <tiwai@suse.de>

[ALSA] Add PnP ID ADS7180

AD1816A driver
Added PnP ID 'ADS7180' (AD1816?).

Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 1da177e4 16-Apr-2005 Linus Torvalds <torvalds@ppc970.osdl.org>

Linux-2.6.12-rc2

Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.

Let it rip!