[arch-commits] Commit in linux/trunk (3 files)

Tobias Powalowski tpowa at nymeria.archlinux.org
Wed Apr 24 06:15:54 UTC 2013


    Date: Wednesday, April 24, 2013 @ 08:15:54
  Author: tpowa
Revision: 183592

upgpkg: linux 3.8.8-2

fix alsa firmware loading #34865

Added:
  linux/trunk/alsa-firmware-loading-3.8.8.patch
Modified:
  linux/trunk/PKGBUILD
  linux/trunk/linux.install

-----------------------------------+
 PKGBUILD                          |   11 +++-
 alsa-firmware-loading-3.8.8.patch |   89 ++++++++++++++++++++++++++++++++++++
 linux.install                     |    2 
 3 files changed, 98 insertions(+), 4 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2013-04-24 05:09:44 UTC (rev 183591)
+++ PKGBUILD	2013-04-24 06:15:54 UTC (rev 183592)
@@ -6,7 +6,7 @@
 #pkgbase=linux-custom       # Build kernel with a different name
 _srcname=linux-3.8
 pkgver=3.8.8
-pkgrel=1
+pkgrel=2
 arch=('i686' 'x86_64')
 url="http://www.kernel.org/"
 license=('GPL2')
@@ -18,13 +18,15 @@
         'config' 'config.x86_64'
         # standard config files for mkinitcpio ramdisk
         'linux.preset'
-        'change-default-console-loglevel.patch')
+        'change-default-console-loglevel.patch'
+        'alsa-firmware-loading-3.8.8.patch')
 md5sums=('1c738edfc54e7c65faeb90c436104e2f'
          '08cdcef928c2ca402adf1c444a3c43ac'
          '838191b72463b4146bc981b602423311'
          '0bebd8b31487488bd75fe5a1892d0db8'
          'eb14dcfd80c00852ef81ded6e826826a'
-         'f3def2cefdcbb954c21d8505d23cc83c')
+         'f3def2cefdcbb954c21d8505d23cc83c'
+         'e2ac681ffa439e969b4c3b4616852454')
 
 _kernelname=${pkgbase#linux}
 
@@ -37,6 +39,9 @@
   # add latest fixes from stable queue, if needed
   # http://git.kernel.org/?p=linux/kernel/git/stable/stable-queue.git
 
+  # fix alsa firmware loading #34865
+  patch -Np1 -i "${srcdir}/alsa-firmware-loading-3.8.8.patch"
+
   # set DEFAULT_CONSOLE_LOGLEVEL to 4 (same value as the 'quiet' kernel param)
   # remove this when a Kconfig knob is made available by upstream
   # (relevant patch sent upstream: https://lkml.org/lkml/2011/7/26/227)

Added: alsa-firmware-loading-3.8.8.patch
===================================================================
--- alsa-firmware-loading-3.8.8.patch	                        (rev 0)
+++ alsa-firmware-loading-3.8.8.patch	2013-04-24 06:15:54 UTC (rev 183592)
@@ -0,0 +1,89 @@
+diff --git a/include/sound/emu10k1.h b/include/sound/emu10k1.h
+index f841ba4..dfb42ca 100644
+--- a/include/sound/emu10k1.h
++++ b/include/sound/emu10k1.h
+@@ -1787,6 +1787,7 @@ struct snd_emu10k1 {
+ 	unsigned int next_free_voice;
+ 
+ 	const struct firmware *firmware;
++	const struct firmware *dock_fw;
+ 
+ #ifdef CONFIG_PM_SLEEP
+ 	unsigned int *saved_ptr;
+diff --git a/sound/pci/emu10k1/emu10k1_main.c b/sound/pci/emu10k1/emu10k1_main.c
+index e6b0166..bdd888e 100644
+--- a/sound/pci/emu10k1/emu10k1_main.c
++++ b/sound/pci/emu10k1/emu10k1_main.c
+@@ -657,14 +657,14 @@ static int snd_emu10k1_cardbus_init(struct snd_emu10k1 *emu)
+ 	return 0;
+ }
+ 
+-static int snd_emu1010_load_firmware(struct snd_emu10k1 *emu)
++static int snd_emu1010_load_firmware(struct snd_emu10k1 *emu,
++				     const struct firmware *fw_entry)
+ {
+ 	int n, i;
+ 	int reg;
+ 	int value;
+ 	unsigned int write_post;
+ 	unsigned long flags;
+-	const struct firmware *fw_entry = emu->firmware;
+ 
+ 	if (!fw_entry)
+ 		return -EIO;
+@@ -725,9 +725,34 @@ static int emu1010_firmware_thread(void *data)
+ 			/* Return to Audio Dock programming mode */
+ 			snd_printk(KERN_INFO "emu1010: Loading Audio Dock Firmware\n");
+ 			snd_emu1010_fpga_write(emu, EMU_HANA_FPGA_CONFIG, EMU_HANA_FPGA_CONFIG_AUDIODOCK);
+-			err = snd_emu1010_load_firmware(emu);
+-			if (err != 0)
+-				continue;
++
++			if (!emu->dock_fw) {
++				const char *filename = NULL;
++				switch (emu->card_capabilities->emu_model) {
++				case EMU_MODEL_EMU1010:
++					filename = DOCK_FILENAME;
++					break;
++				case EMU_MODEL_EMU1010B:
++					filename = MICRO_DOCK_FILENAME;
++					break;
++				case EMU_MODEL_EMU1616:
++					filename = MICRO_DOCK_FILENAME;
++					break;
++				}
++				if (filename) {
++					err = request_firmware(&emu->dock_fw,
++							       filename,
++							       &emu->pci->dev);
++					if (err)
++						continue;
++				}
++			}
++
++			if (emu->dock_fw) {
++				err = snd_emu1010_load_firmware(emu, emu->dock_fw);
++				if (err)
++					continue;
++			}
+ 
+ 			snd_emu1010_fpga_write(emu, EMU_HANA_FPGA_CONFIG, 0);
+ 			snd_emu1010_fpga_read(emu, EMU_HANA_IRQ_STATUS, &reg);
+@@ -862,7 +887,7 @@ static int snd_emu10k1_emu1010_init(struct snd_emu10k1 *emu)
+ 			   filename, emu->firmware->size);
+ 	}
+ 
+-	err = snd_emu1010_load_firmware(emu);
++	err = snd_emu1010_load_firmware(emu, emu->firmware);
+ 	if (err != 0) {
+ 		snd_printk(KERN_INFO "emu1010: Loading Firmware failed\n");
+ 		return err;
+@@ -1253,6 +1278,8 @@ static int snd_emu10k1_free(struct snd_emu10k1 *emu)
+ 		kthread_stop(emu->emu1010.firmware_thread);
+ 	if (emu->firmware)
+ 		release_firmware(emu->firmware);
++	if (emu->dock_fw)
++		release_firmware(emu->dock_fw);
+ 	if (emu->irq >= 0)
+ 		free_irq(emu->irq, emu);
+ 	/* remove reserved page */
\ No newline at end of file

Modified: linux.install
===================================================================
--- linux.install	2013-04-24 05:09:44 UTC (rev 183591)
+++ linux.install	2013-04-24 06:15:54 UTC (rev 183592)
@@ -2,7 +2,7 @@
 # arg 2:  the old package version
 
 KERNEL_NAME=
-KERNEL_VERSION=3.8.8-1-ARCH
+KERNEL_VERSION=3.8.8-2-ARCH
 
 # set a sane PATH to ensure that critical utils like depmod will be found
 export PATH='/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin'




More information about the arch-commits mailing list