History log of /linux-master/sound/drivers/vx/vx_core.c
Revision Date Author Comments
# a0339541 15-Jul-2021 Takashi Iwai <tiwai@suse.de>

ALSA: vx: Manage vx_core object with devres

The firmware data are also released automatically.

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


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

ALSA: vx: Fix assignment in if condition

VX driver helper 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-61-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 60fd7115 02-Mar-2021 Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

ALSA: vx: fix kernel-doc warning

make W=1 warning:

sound/drivers/vx/vx_core.c:410: warning: expecting prototype for
snd_vx_boot_xilinx(). Prototype was for snd_vx_load_boot_image()
instead

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20210302215430.87309-2-pierre-louis.bossart@linux.intel.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# b7dcd6ac 02-Sep-2020 Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

ALSA: vx: vx_core: clarify operator precedence

Fix cppcheck warning

sound/drivers/vx/vx_core.c:600:49: style: Clarify calculation
precedence for '&' and '?'. [clarifyCalculation]
chip->chip_status & VX_STAT_XILINX_LOADED ? "Loaded" : "No");
^
sound/drivers/vx/vx_core.c:602:47: style: Clarify calculation
precedence for '&' and '?'. [clarifyCalculation]
chip->chip_status & VX_STAT_DEVICE_INIT ? "Yes" : "No");
^

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200902212133.30964-17-pierre-louis.bossart@linux.intel.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 5ddf2dfe 02-Jul-2020 Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

ALSA: vx_core: remove warning for empty loop body

Fix W=1 warning.

sound/drivers/vx/vx_core.c: In function ‘snd_vx_threaded_irq_handler’:
sound/drivers/vx/vx_core.c:515:3: warning: suggest braces around empty
body in an ‘if’ statement [-Wempty-body]
515 | ; /* so far, nothing to do yet */
| ^

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200702193604.169059-23-pierre-louis.bossart@linux.intel.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# c0948245 05-Jan-2020 Takashi Iwai <tiwai@suse.de>

ALSA: vx: More constifications

Apply const prefix to every possible place: the static tables for DSP
commands, the string tables, and register/offset tables.

Just for minor optimization and no functional changes.

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


# f8ae2d29 03-Jan-2020 Takashi Iwai <tiwai@suse.de>

ALSA: vx: Constify snd_vx_hardware and snd_vx_ops definitions

Both snd_vx_hardware and snd_vx_ops are only referred without
modification, hence they can be constified gracefully for further
optimizations.

There should be no functional changes by this patch.

Link: https://lore.kernel.org/r/20200103081714.9560-31-tiwai@suse.de
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>


# 815d808c 04-Feb-2019 Takashi Iwai <tiwai@suse.de>

ALSA: drivers: Clean up with new procfs helpers

Simplify the proc fs creation code with new helper functions,
snd_card_ro_proc_new() and snd_card_rw_proc_new().
Just a code refactoring and no functional changes.

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


# 3c40dfeb 11-Jan-2019 Takashi Iwai <tiwai@suse.de>

ALSA: drivers: Remove superfluous snd_pcm_suspend*() calls

The call of snd_pcm_suspend_all() & co became superfluous since we
call it in the PCM PM ops. Let's remove them.

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


# 969686ee 03-Aug-2018 Takashi Iwai <tiwai@suse.de>

ALSA: drivers: Remove empty init and exit

For a sake of code simplification, remove the init and the exit
entries that do nothing.

Notes for readers: actually it's OK to remove *both* init and exit,
but not OK to remove the exit entry. By removing only the exit while
keeping init, the module becomes permanently loaded; i.e. you cannot
unload it any longer!

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


# 07f070dd 31-Aug-2017 Takashi Iwai <tiwai@suse.de>

ALSA: vx: Put missing KERN_CONT prefix

The vx driver has a debug printk code without proper KERN_ prefix.
On recent kernels, KERN_CONT prefix is mandatory for continued output
lines. Put it properly.

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


# a65895e0 25-Feb-2017 Mihai Burduselu <michelcatalin@gmail.com>

ALSA: vx: remove 'out of memory' message

Reported by checkpatch.pl

Signed-off-by: Mihai Burduselu <michelcatalin@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 6cbbfe1c 28-Jan-2015 Takashi Iwai <tiwai@suse.de>

ALSA: Include linux/io.h instead of asm/io.h

Nowadays it's recommended. Replace all in a shot.

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


# 2a9e8df0 10-Nov-2014 Takashi Iwai <tiwai@suse.de>

ALSA: vx: Fix missing kerneldoc parameter descriptions

The file isn't processed, but it's not bad to fix beforehand.

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


# db0a5214 09-Sep-2014 Takashi Iwai <tiwai@suse.de>

ALSA: vx: Use nonatomic PCM ops

Rewrite VXpocket and VX222 drivers to use the new PCM nonatomic ops.
The former irq tasklet is replaced with a threaded irq handler, and
the tasklet for the PCM delayed start is simply merged into the normal
PCM trigger, as well as the replacement of spinlock with mutex.

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


# fefe228c 21-Jun-2013 Dan Carpenter <dan.carpenter@oracle.com>

ALSA: vx_core: off by one in vx_read_status()

This code is older than git, and I haven't tested it, but if size ==
SIZE_MAX_STATUS then we would write one space past the end of the
rmh->Stat[] array.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 86b27237 25-Jan-2013 Takashi Iwai <tiwai@suse.de>

ALSA: Make snd_printd() and snd_printdd() inline

Because currently snd_printd() and snd_printdd() macros are expanded
to empty when CONFIG_SND_DEBUG=n, a compile warning like below
appears sometimes, and we had to covert it by ugly ifdefs:
sound/pci/hda/patch_sigmatel.c: In function ‘stac92hd71bxx_fixup_hp’:
sound/pci/hda/patch_sigmatel.c:2434:24: warning: unused variable ‘spec’ [-Wunused-variable]

For "fixing" these issues better, this patch replaces snd_printd() and
snd_printdd() definitions with empty inline functions instead of
macros. This should have the same effect but shut up warnings like
above.

But since we had already put ifdefs, changing to inline functions
would trigger compile errors. So, such ifdefs is removed in this
patch.

In addition, snd_pci_quirk name field is defined only when
CONFIG_SND_DEBUG_VERBOSE is set, and the reference to it in
snd_printdd() argument triggers the build errors, too. For avoiding
these errors, introduce a new macro snd_pci_quirk_name() that is
defined no matter how the debug option is set.

Reported-by: Stratos Karafotis <stratosk@semaphore.gr>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


# 68cb2b55 02-Jul-2012 Takashi Iwai <tiwai@suse.de>

ALSA: Convert to new pm_ops for PCI drivers

Straightforward conversion to the new pm_ops from the legacy
suspend/resume ops.

Since we change vx222, vx_core and vxpocket have to be converted,
too.

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


# da155d5b 14-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com>

sound: Add module.h to the previously silent sound users

Lots of sound drivers were getting module.h via the implicit presence
of it in <linux/device.h> but we are going to clean that up. So
fix up those users now.

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


# 45203832 05-Feb-2009 Takashi Iwai <tiwai@suse.de>

ALSA: Add missing KERN_* prefix to printk in sound/drivers

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


# 1f04128a 17-Dec-2008 Takashi Iwai <tiwai@suse.de>

ALSA: hda - Convert from takslet_hi_schedule() to tasklet_schedule()

Replace all tasklet_hi_schedule() callers with the normal
tasklet_schedule(). The former often causes troubles with
RT-kernels, and has actually no merit.

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


# 5e246b85 08-Aug-2008 Takashi Iwai <tiwai@suse.de>

ALSA: Kill snd_assert() in other places

Kill snd_assert() in other places, either removed or replaced with
if () with snd_BUG_ON().

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


# 2f0600b6 23-May-2008 David Woodhouse <dwmw2@infradead.org>

vx: treat firmware data as const

Signed-off-by: David Woodhouse <dwmw2@infradead.org>


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


# 7d12e780 05-Oct-2006 David Howells <dhowells@redhat.com>

IRQ: Maintain regs pointer globally rather than passing to IRQ handlers

Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
of passing regs around manually through all ~1800 interrupt handlers in the
Linux kernel.

The regs pointer is used in few places, but it potentially costs both stack
space and code to pass it around. On the FRV arch, removing the regs parameter
from all the genirq function results in a 20% speed up of the IRQ exit path
(ie: from leaving timer_interrupt() to leaving do_IRQ()).

Where appropriate, an arch may override the generic storage facility and do
something different with the variable. On FRV, for instance, the address is
maintained in GR28 at all times inside the kernel as part of general exception
handling.

Having looked over the code, it appears that the parameter may be handed down
through up to twenty or so layers of functions. Consider a USB character
device attached to a USB hub, attached to a USB controller that posts its
interrupts through a cascaded auxiliary interrupt controller. A character
device driver may want to pass regs to the sysrq handler through the input
layer which adds another few layers of parameter passing.

I've build this code with allyesconfig for x86_64 and i386. I've runtested the
main part of the code on FRV and i386, though I can't test most of the drivers.
I've also done partial conversion for powerpc and MIPS - these at least compile
with minimal configurations.

This will affect all archs. Mostly the changes should be relatively easy.
Take do_IRQ(), store the regs pointer at the beginning, saving the old one:

struct pt_regs *old_regs = set_irq_regs(regs);

And put the old one back at the end:

set_irq_regs(old_regs);

Don't pass regs through to generic_handle_irq() or __do_IRQ().

In timer_interrupt(), this sort of change will be necessary:

- update_process_times(user_mode(regs));
- profile_tick(CPU_PROFILING, regs);
+ update_process_times(user_mode(get_irq_regs()));
+ profile_tick(CPU_PROFILING);

I'd like to move update_process_times()'s use of get_irq_regs() into itself,
except that i386, alone of the archs, uses something other than user_mode().

Some notes on the interrupt handling in the drivers:

(*) input_dev() is now gone entirely. The regs pointer is no longer stored in
the input_dev struct.

(*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking. It does
something different depending on whether it's been supplied with a regs
pointer or not.

(*) Various IRQ handler function pointers have been moved to type
irq_handler_t.

Signed-Off-By: David Howells <dhowells@redhat.com>
(cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)


# bf850204 28-Apr-2006 Takashi Iwai <tiwai@suse.de>

[ALSA] Remove unneeded read/write_size fields in proc text ops

Remove unneeded read/write_size fields in proc text ops.
snd_info_set_text_ops() is fixed, too.

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


# fa325eb3 28-Apr-2006 Takashi Iwai <tiwai@suse.de>

[ALSA] vx - Move EXPORT_SYMBOL() to adjacent to each function

Move EXPORT_SYMBOL() to adjacent to each exported function/variable.

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


# ef9f0a42 16-Jan-2006 Ingo Molnar <mingo@elte.hu>

[ALSA] semaphore -> mutex (driver part)

Semaphore to mutex conversion.

The conversion was generated via scripts, and the result was validated
automatically via a script as well.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>


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

[ALSA] vx-driver - Fix PM support

Fix PM support on VX drivers (vxpocket and vx222).

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


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

[ALSA] Remove xxx_t typedefs: VXdriver

Remove xxx_t typedefs from the VXdriver codes
(vx_core support, vx222 and vxpocket).

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


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

[ALSA] Remove snd_vx_delay() function

Replace snd_vx_delay() with appropriate delay/sleep functions.

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


# 561b220a 09-Sep-2005 Takashi Iwai <tiwai@suse.de>

[ALSA] Replace with kzalloc() - others

Documentation,SA11xx UDA1341 driver,Generic drivers,MPU401 UART,OPL3
OPL4,Digigram VX core,I2C cs8427,I2C lib core,I2C tea6330t,L3 drivers
AK4114 receiver,AK4117 receiver,PDAudioCF driver,PPC PMAC driver
SPARC AMD7930 driver,SPARC cs4231 driver,Synth,Common EMU synth
USB generic driver,USB USX2Y
Replace kcalloc(1,..) with kzalloc().

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!