updated on Fri Jan 6 04:00:21 UTC 2012
[aur-mirror.git] / hdjmod / kernel_2.6.31_fix.patch
blob7050969f71f6e6a464d195d209e592038c3d6d16
1 --- device.c.orig 2009-10-27 19:52:01.000000000 -0400
2 +++ device.c 2009-10-27 19:53:32.000000000 -0400
3 @@ -1660,12 +1660,11 @@
4 /* let the kernel option override custom id */
5 strncpy(card_id,id[idx],sizeof(card_id)-1);
7 - card = snd_card_new(index[idx], card_id/*id[idx]*/, THIS_MODULE, 0);
8 - if (card == NULL) {
9 - snd_printk(KERN_WARNING "snd_hdj_chip_create(): cannot create card instance %d\n", idx);
10 - return -ENOMEM;
11 - }
13 + err = snd_card_create(index[idx], card_id/*id[idx]*/, THIS_MODULE, 0, &card);
14 + if (err < 0) {
15 + snd_printk(KERN_WARNING "snd_hdj_chip_create(): cannot create card instance %d\n", idx);
16 + return err;
17 + }
18 /* save the index, so people who have the card can reference the chip */
19 card->private_data = (void*)(unsigned long)idx;