Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1704763 > unrolled thread
| Started by | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| First post | 2017-08-06 09:00 +0200 |
| Last post | 2017-08-06 22:30 +0200 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH 0/7] constify ALSA usb_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-06 09:00 +0200
[PATCH 7/7] ALSA: usbusx2y: constify usb_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-06 09:00 +0200
Re: [PATCH 0/7] constify ALSA usb_device_id. Takashi Iwai <tiwai@suse.de> - 2017-08-06 22:30 +0200
| From | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| Date | 2017-08-06 09:00 +0200 |
| Subject | [PATCH 0/7] constify ALSA usb_device_id. |
| Message-ID | <ubnxT-7cN-3@gated-at.bofh.it> |
usb_device_id are not supposed to change at runtime. All functions working with usb_device_id provided by <linux/usb.h> work with const usb_device_id. So mark the non-const structs as const. Arvind Yadav (7): [PATCH 1/7] ALSA: 6fire: constify usb_device_id. [PATCH 2/7] ALSA: bcd2000: constify usb_device_id. [PATCH 3/7] ALSA: snd-usb-caiaq: constify usb_device_id. [PATCH 4/7] ALSA: usb-audio: constify usb_device_id. [PATCH 5/7] ALSA: ua101: constify usb_device_id. [PATCH 6/7] ALSA: us122l: constify usb_device_id. [PATCH 7/7] ALSA: usbusx2y: constify usb_device_id. sound/usb/6fire/chip.c | 2 +- sound/usb/bcd2000/bcd2000.c | 2 +- sound/usb/caiaq/device.c | 2 +- sound/usb/card.c | 4 ++-- sound/usb/misc/ua101.c | 2 +- sound/usb/usx2y/us122l.c | 2 +- sound/usb/usx2y/usbusx2y.c | 2 +- 7 files changed, 8 insertions(+), 8 deletions(-) -- 2.7.4
[toc] | [next] | [standalone]
| From | Arvind Yadav <arvind.yadav.cs@gmail.com> |
|---|---|
| Date | 2017-08-06 09:00 +0200 |
| Subject | [PATCH 7/7] ALSA: usbusx2y: constify usb_device_id. |
| Message-ID | <ubnHz-7g5-5@gated-at.bofh.it> |
| In reply to | #1704763 |
usb_device_id are not supposed to change at runtime. All functions
working with usb_device_id provided by <linux/usb.h> work with
const usb_device_id. So mark the non-const structs as const.
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
sound/usb/usx2y/usbusx2y.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/usb/usx2y/usbusx2y.c b/sound/usb/usx2y/usbusx2y.c
index 91e0e2a..4569c0e 100644
--- a/sound/usb/usx2y/usbusx2y.c
+++ b/sound/usb/usx2y/usbusx2y.c
@@ -313,7 +313,7 @@ static void usX2Y_unlinkSeq(struct snd_usX2Y_AsyncSeq *S)
}
-static struct usb_device_id snd_usX2Y_usb_id_table[] = {
+static const struct usb_device_id snd_usX2Y_usb_id_table[] = {
{
.match_flags = USB_DEVICE_ID_MATCH_DEVICE,
.idVendor = 0x1604,
--
2.7.4
[toc] | [prev] | [next] | [standalone]
| From | Takashi Iwai <tiwai@suse.de> |
|---|---|
| Date | 2017-08-06 22:30 +0200 |
| Message-ID | <ubAls-6Rf-15@gated-at.bofh.it> |
| In reply to | #1704763 |
On Sun, 06 Aug 2017 08:48:52 +0200, Arvind Yadav wrote: > > usb_device_id are not supposed to change at runtime. All functions > working with usb_device_id provided by <linux/usb.h> work with > const usb_device_id. So mark the non-const structs as const. > > Arvind Yadav (7): > [PATCH 1/7] ALSA: 6fire: constify usb_device_id. > [PATCH 2/7] ALSA: bcd2000: constify usb_device_id. > [PATCH 3/7] ALSA: snd-usb-caiaq: constify usb_device_id. > [PATCH 4/7] ALSA: usb-audio: constify usb_device_id. > [PATCH 5/7] ALSA: ua101: constify usb_device_id. > [PATCH 6/7] ALSA: us122l: constify usb_device_id. > [PATCH 7/7] ALSA: usbusx2y: constify usb_device_id. Applied all seven patches now. Thanks. Takashi
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web