aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/ctxfi/ctresource.h (follow)
AgeCommit message (Collapse)AuthorFilesLines
2021-11-18ALSA: ctxfi: Fix out-of-range accessTakashi Iwai1-2/+2
The master and next_conj of rcs_ops are used for iterating the resource list entries, and currently those are supposed to return the current value. The problem is that next_conf may go over the last entry before the loop abort condition is evaluated, and it may return the "current" value that is beyond the array size. It was caught recently as a GPF, for example. Those return values are, however, never actually evaluated, hence basically we don't have to consider the current value as the return at all. By dropping those return values, the potential out-of-range access above is also fixed automatically. This patch changes the return type of master and next_conj callbacks to void and drop the superfluous code accordingly. BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=214985 Cc: <stable@vger.kernel.org> Link: https://lore.kernel.org/r/20211118215729.26257-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
2021-03-18ALSA: ctxfi: fix comment syntax in file headersAditya Srivastava1-1/+1
The opening comment mark '/**' is used for highlighting the beginning of kernel-doc comments. There are files in sound/pci/ctxfi which follow this syntax in their file headers, i.e. start with '/**' like comments, which causes unexpected warnings from kernel-doc. E.g., running scripts/kernel-doc -none on sound/pci/ctxfi/ctresource.c causes this warning: "warning: wrong kernel-doc identifier on line: * Copyright (C) 2008, Creative Technology Ltd. All Rights Reserved." Similarly for other files too. Provide a simple fix by replacing the kernel-doc like comment syntax with general format, i.e. "/*", to prevent kernel-doc from parsing it. Signed-off-by: Aditya Srivastava <yashsri421@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> Link: https://lore.kernel.org/r/20210317203932.23993-1-yashsri421@gmail.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
2019-06-05treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 364Thomas Gleixner1-5/+1
Based on 1 normalized pattern(s): this source file is released under gpl v2 license no other versions see the copying file included in the main directory of this source distribution for the license terms and conditions extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 28 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Reviewed-by: Armijn Hemel <armijn@tjaldur.nl> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190531081035.780831265@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-11-11ALSA: ctxfi: constify rsc ops structuresJulia Lawall1-1/+1
The various rsc ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2014-09-30ALSA: ctxfi: changed void * to struct hw *Sudip Mukherjee1-4/+5
in the code we have void *hw and while using we are always typecasting it to (struct hw *). it is better to use void type of pointer when we store different types of pointer , but in this code we are only having struct hw. So changed all the relevant reference of void *hw to struct hw *hw, without any modification of the existing code logic. the next patch of the series will remove the typecasting which is not required now. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-14ALSA: SB X-Fi driver mergeWai Yew CHAY1-0/+72
The Sound Blaster X-Fi driver supports Creative solutions based on 20K1 and 20K2 chipsets. Supported hardware : Creative Sound Blaster X-Fi Titanium Fatal1ty® Champion Series Creative Sound Blaster X-Fi Titanium Fatal1ty Professional Series Creative Sound Blaster X-Fi Titanium Professional Audio Creative Sound Blaster X-Fi Titanium Creative Sound Blaster X-Fi Elite Pro Creative Sound Blaster X-Fi Platinum Creative Sound Blaster X-Fi Fatal1ty Creative Sound Blaster X-Fi XtremeGamer Creative Sound Blaster X-Fi XtremeMusic Current release features: * ALSA PCM Playback * ALSA Record * ALSA Mixer Note: * External I/O modules detection not included. Signed-off-by: Wai Yew CHAY <wychay@ctl.creative.com> Singed-off-by: Ryan RICHARDS <ryan_richards@creativelabs.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>