[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-08-09 Thread Mark Haidekker
Strange... I did not yet see any response, comment, note, whatever, in
response to my bug preport. Did I do something wrong?

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Triaged

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group
  dmi.chassis.asset.tag: None
  

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-12 Thread Christopher M. Penalver
http://vger.kernel.org/vger-lists.html#linux-sound

** Tags added: kernel-sound

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Triaged

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group
  dmi.chassis.asset.tag: None
  dmi.chassis.type: 3
  dmi.chassis.vendor: BIOSTAR 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-12 Thread Mark Haidekker
As requested, here is the URL to my e-mail.

http://marc.info/?l=linux-soundm=140260354628114

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Triaged

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group
  dmi.chassis.asset.tag: None
  dmi.chassis.type: 3
  

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Christopher M. Penalver
Mark Haidekker, thank you for reporting this and helping make Ubuntu better. 
Could you please test the latest upstream kernel available from the first line 
at the top page (not the daily folder) following 
https://wiki.ubuntu.com/KernelMainlineBuilds ? It will allow additional 
upstream developers to examine the issue. Once you've tested the upstream 
kernel, please comment on which kernel version specifically you tested. If this 
bug is fixed in the mainline kernel, please add the following tags:
kernel-fixed-upstream
kernel-fixed-upstream-VERSION-NUMBER

where VERSION-NUMBER is the version number of the kernel you tested. For 
example:
kernel-fixed-upstream-3.15

This can be done by clicking on the yellow circle with a black pencil icon next 
to the word Tags located at the bottom of the bug description. As well, please 
remove the tag:
needs-upstream-testing

If the mainline kernel does not fix this bug, please add the following tags:
kernel-bug-exists-upstream
kernel-bug-exists-upstream-VERSION-NUMBER

As well, please remove the tag:
needs-upstream-testing

Once testing of the upstream kernel is complete, please mark this bug's
Status as Confirmed. Please let us know your results. Thank you for your
understanding.

** Description changed:

  This bug has been around for a while. I have seen it in the forums circa
  2007, and I have provided a solution in 2009. Since the modified code
  never found its way into the mainstream kernels, I am issuing the fix as
  a bug report.
  
  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip in
  both i386 and amd64 architectures, in any kernel (standard, RT etc).
  They have on-board joystick MIDI. There is an optional front-panel
  module, which provides its own MIDI UART. Under Linux, the front MIDI
  does not work. People with dual-boot systems have reported that booting
  Windows first, then rebooting into Linux makes the UART function
  properly.
  
  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after power-
  up. Up to this point, the GPIO _levels_ are initialized correctly, but
  the reset _pulse_ is never issued. Essentially, the emu10k1 chip's GPIO2
  needs to be pulled high for a brief interval.
  
- The bug can be fixed in the file linux-
- source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function
- snd_emu10k1_audigy_midi(). The proposed patch follows right after the
- present initialization of the second UART (note the added variable val
- to store the GPIO bits):
- 
+ WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */
  
   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;
  
   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;
  
   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;
  
   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;
  
   /*** NEW CODE ***  Pulse reset line for the second UART */
  
   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);
  
   return 0;
  }
  
  I suspect that my use of udelay would make a real kernel hacker cringe,
  but the level of GPOUT2 needs to remain high for a few microseconds to
  provide a stable RESET signal.
  
  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
- --- 
+ ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
-  USERPID ACCESS COMMAND
-  /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
-  /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
-  /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
+  USERPID ACCESS COMMAND
+  /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
+  /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
+  /dev/snd/controlC0:  mhaidekk   

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
I am planning to try it with the 3.15 RT kernel -- could you please
point me in the direction of the matching source code, either .deb or
tar? I think the test would be kind of pointless if I tried the upstream
kernel without applying my patch, since I'd be unsurprised if the bug
was still there.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Incomplete

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
Never mind... I found the kernel source.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Incomplete

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group
  dmi.chassis.asset.tag: None
  dmi.chassis.type: 3
  dmi.chassis.vendor: BIOSTAR Group
  dmi.modalias: 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
OK, here are the results:

* Tested with kernel version 3.15.0-031500-lowlatency, specifically the
mainline kernel file linux-
image-3.15.0-031500-lowlatency_3.15.0-031500.201406111300_amd64.deb and
the associated header file.

* Bug persists in the tested kernel version = front panel MIDI uart is
unable to receive

* Downloaded kernel source linux-source-3.15.0

* Patched file emump401.c (see attached file), built kernel, installed
kernel (this one has the build number linux-
image-3.15.0-rc8_3.15.0-rc8-2_amd64)

* Cold-started computer (cold start is necessary to force the MINI
microcontroller into its power-up state without the reset pulse)

* Bug fixed, front panel MIDI works.


** Attachment added: emumpu401.c
   
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1328746/+attachment/4129882/+files/emumpu401.c

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Confirmed

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
Here is the file. This file replaces /usr/src/linux-
source-3.15.0/sound/pci/emu10k1/emumpu401.c

This is the only file that needs to be modified. Kernel build works
without errors with this file.

** Attachment added: Attchment contains solution; is replacement file
   
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1328746/+attachment/4129883/+files/emumpu401.c

** Tags removed: apport-collected trusty
** Tags added: kernel-bug-exists-upstream kernel-bug-exists-upstream-3.15.0

** Changed in: linux (Ubuntu)
   Status: Incomplete = Confirmed

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Confirmed

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
** Attachment removed: emumpu401.c
   
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1328746/+attachment/4129882/+files/emumpu401.c

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Confirmed

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group
  dmi.chassis.asset.tag: 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Christopher M. Penalver
Mark Haidekker, the issue you are reporting is an upstream one. Could
you please report this problem through the appropriate channel by
following the instructions _verbatim_ at
https://wiki.ubuntu.com/Bugs/Upstream/kernel ?

Please provide a direct URL to your e-mail to the mailing list once you
have made it so that it may be tracked.

Thank you for your understanding.

** Tags removed: kernel-bug-exists-upstream-3.15.0
** Tags added: apport-collected kernel-bug-exists-upstream-3.15 trusty

** Changed in: linux (Ubuntu)
   Status: Confirmed = Triaged

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Triaged

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-11 Thread Mark Haidekker
H. I am running into a serious challenge here. I am OK with the
first step (collecting the information that goes into the e-mail), but
stymied by Step 2. Step 2, section Reporting non-USB bugs upstream
states that I need to identify the maintainer in the MAINTAINERS list.
Unfortunately, there is no entry for emu10k1, thus (probably) no
maintainer. There is also no pattern in the sound/pci section which
indicates an individual or group who is repsonsible for that part.

Advice?

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Triaged

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  WORKAROUND: The bug can be fixed in the file 
linux-source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function 
snd_emu10k1_audigy_midi(). The proposed patch follows right after the present 
initialization of the second UART (note the added variable val to store the 
GPIO bits):
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  ---
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.

   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:

  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-10 Thread Mark Haidekker
** Description changed:

  This bug has been around for a while. I have seen it in the forums circa
  2007, and I have provided a solution in 2009. Since the modified code
  never found its way into the mainstream kernels, I am issuing the fix as
  a bug report.
  
  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip in
  both i386 and amd64 architectures, in any kernel (standard, RT etc).
  They have on-board joystick MIDI. There is an optional front-panel
- module, which provides its own MIDI UART. Under Liunux, the front MIDI
- does not work. People wuth dual-boot systems have reported that booting
+ module, which provides its own MIDI UART. Under Linux, the front MIDI
+ does not work. People with dual-boot systems have reported that booting
  Windows first, then rebooting into Linux makes the UART function
  properly.
  
  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
- and this microcontroller needs a defined reset signal. Up to this point,
- the GPIO _levels_ are initialized correctly, but the reset pulse is
- never issued.
+ and this microcontroller needs a defined reset signal once after power-
+ up. Up to this point, the GPIO _levels_ are initialized correctly, but
+ the reset _pulse_ is never issued. Essentially, the emu10k1 chip's GPIO2
+ needs to be pulled high for a brief interval.
  
  The bug can be fixed in the file linux-
  source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function
  snd_emu10k1_audigy_midi(). The proposed patch follows right after the
- present initialization of the second UART:
- 
+ present initialization of the second UART (note the added variable val
+ to store the GPIO bits):
  
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
-   struct snd_emu10k1_midi *midi;
-   int err;
-   unsigned int val;   /* Needed in GPOUT2 pulse 
initialization */
+  struct snd_emu10k1_midi *midi;
+  int err;
+  unsigned int val;/* Needed in GPOUT2 pulse initialization */
  
-   midi = emu-midi;
-   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  
0)
-   return err;
+  midi = emu-midi;
+  if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
+   return err;
  
-   midi-tx_enable = INTE_MIDITXENABLE;
-   midi-rx_enable = INTE_MIDIRXENABLE;
-   midi-port = A_MUDATA1;
-   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
-   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
-   midi-interrupt = snd_emu10k1_midi_interrupt;
+  midi-tx_enable = INTE_MIDITXENABLE;
+  midi-rx_enable = INTE_MIDIRXENABLE;
+  midi-port = A_MUDATA1;
+  midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
+  midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
+  midi-interrupt = snd_emu10k1_midi_interrupt;
  
-   midi = emu-midi2;
-   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
-   return err;
+  midi = emu-midi2;
+  if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
+   return err;
  
-   midi-tx_enable = INTE_A_MIDITXENABLE2;
-   midi-rx_enable = INTE_A_MIDIRXENABLE2;
-   midi-port = A_MUDATA2;
-   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
-   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
-   midi-interrupt = snd_emu10k1_midi_interrupt2;
+  midi-tx_enable = INTE_A_MIDITXENABLE2;
+  midi-rx_enable = INTE_A_MIDIRXENABLE2;
+  midi-port = A_MUDATA2;
+  midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
+  midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
+  midi-interrupt = snd_emu10k1_midi_interrupt2;
  
- /*** NEW CODE ***  Pulse reset line for the second UART */
+  /*** NEW CODE ***  Pulse reset line for the second UART */
  
-   val = inl(emu-port + A_IOCFG);
-   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
-   udelay(10); /* udelay is a bad kludge, but remember that 
this is called only once on startup */
-   outl (val, emu-port + A_IOCFG);
+  val = inl(emu-port + A_IOCFG);
+  outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
+  udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
+  outl (val, emu-port + A_IOCFG);
  
-   return 0;
+  return 0;
  }
  
- 
- I suspect that my use of udelay would make a real kernel hacker cringe, but 
the level of GPOUT2 needs to remain high for a few microseconds to provide a 
stable RESET signal.
+ I suspect that my use of udelay would make a real kernel hacker cringe,
+ but the level of GPOUT2 needs to remain high for a few microseconds to
+ provide a stable RESET signal.
  
  Anyway, this fixes the problem. I have applied the patch for pretty much
  every major upgrade of the kernel. It is sufficient to compile the
  module snd-emu10k1.ko and replace it in the module tree.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-10 Thread Mark Haidekker
apport information

** Tags added: apport-collected trusty

** Description changed:

  This bug has been around for a while. I have seen it in the forums circa
  2007, and I have provided a solution in 2009. Since the modified code
  never found its way into the mainstream kernels, I am issuing the fix as
  a bug report.
  
  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip in
  both i386 and amd64 architectures, in any kernel (standard, RT etc).
  They have on-board joystick MIDI. There is an optional front-panel
  module, which provides its own MIDI UART. Under Linux, the front MIDI
  does not work. People with dual-boot systems have reported that booting
  Windows first, then rebooting into Linux makes the UART function
  properly.
  
  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after power-
  up. Up to this point, the GPIO _levels_ are initialized correctly, but
  the reset _pulse_ is never issued. Essentially, the emu10k1 chip's GPIO2
  needs to be pulled high for a brief interval.
  
  The bug can be fixed in the file linux-
  source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function
  snd_emu10k1_audigy_midi(). The proposed patch follows right after the
  present initialization of the second UART (note the added variable val
  to store the GPIO bits):
  
  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */
  
   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;
  
   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;
  
   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;
  
   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;
  
   /*** NEW CODE ***  Pulse reset line for the second UART */
  
   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);
  
   return 0;
  }
  
  I suspect that my use of udelay would make a real kernel hacker cringe,
  but the level of GPOUT2 needs to remain high for a few microseconds to
  provide a stable RESET signal.
  
- Anyway, this fixes the problem. I have applied the patch for pretty much
- every major upgrade of the kernel. It is sufficient to compile the
- module snd-emu10k1.ko and replace it in the module tree.
+ Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
+ --- 
+ ApportVersion: 2.14.1-0ubuntu3.2
+ Architecture: amd64
+ AudioDevicesInUse:
+  USERPID ACCESS COMMAND
+  /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
+  /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
+  /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
+ CRDA: Error: [Errno 2] No such file or directory
+ CurrentDesktop: KDE
+ DistroRelease: Ubuntu 14.04
+ EcryptfsInUse: Yes
+ HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
+ InstallationDate: Installed on 2013-12-31 (161 days ago)
+ InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
+ IwConfig:
+  eth1  no wireless extensions.
+  
+  lono wireless extensions.
+ MachineType: BIOSTAR Group TA970
+ NonfreeKernelModules: fglrx
+ Package: linux (not installed)
+ ProcFB: 0 VESA VGA
+ ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
+ ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
+ RelatedPackageVersions:
+  linux-restricted-modules-3.13.0-29-generic N/A
+  linux-backports-modules-3.13.0-29-generic  N/A
+  linux-firmware 1.127.2
+ RfKill:
+  
+ Tags:  trusty
+ Uname: Linux 3.13.0-29-generic x86_64
+ UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
+ UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
+ _MarkForUpload: True
+ dmi.bios.date: 01/14/2013
+ dmi.bios.vendor: American Megatrends Inc.
+ dmi.bios.version: 4.6.4
+ dmi.board.asset.tag: None
+ dmi.board.name: TA970
+ dmi.board.vendor: BIOSTAR Group
+ dmi.chassis.asset.tag: None
+ dmi.chassis.type: 3
+ dmi.chassis.vendor: BIOSTAR Group
+ dmi.modalias: 

[Kernel-packages] [Bug 1328746] Re: Soundblaster Audigy front panel MIDI fails to initialize

2014-06-10 Thread Mark Haidekker
Please note that the entire apport information is irrelevant in this
context.


** Changed in: linux (Ubuntu)
   Status: Incomplete = Confirmed

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1328746

Title:
  Soundblaster Audigy front panel MIDI fails to initialize

Status in “linux” package in Ubuntu:
  Confirmed

Bug description:
  This bug has been around for a while. I have seen it in the forums
  circa 2007, and I have provided a solution in 2009. Since the modified
  code never found its way into the mainstream kernels, I am issuing the
  fix as a bug report.

  The bug concerns the Soundblaster Audigy cards with the emu10k1 chip
  in both i386 and amd64 architectures, in any kernel (standard, RT
  etc). They have on-board joystick MIDI. There is an optional front-
  panel module, which provides its own MIDI UART. Under Linux, the front
  MIDI does not work. People with dual-boot systems have reported that
  booting Windows first, then rebooting into Linux makes the UART
  function properly.

  The cause for the bug lies in the fact that the front panel MIDI is
  routed through a microcontroller (resides in the front panel module),
  and this microcontroller needs a defined reset signal once after
  power-up. Up to this point, the GPIO _levels_ are initialized
  correctly, but the reset _pulse_ is never issued. Essentially, the
  emu10k1 chip's GPIO2 needs to be pulled high for a brief interval.

  The bug can be fixed in the file linux-
  source-3.13.0/sound/pci/emu10k1/emumpu401.c in the function
  snd_emu10k1_audigy_midi(). The proposed patch follows right after the
  present initialization of the second UART (note the added variable
  val to store the GPIO bits):

  int snd_emu10k1_audigy_midi(struct snd_emu10k1 *emu)
  {
   struct snd_emu10k1_midi *midi;
   int err;
   unsigned int val;/* Needed in GPOUT2 pulse initialization */

   midi = emu-midi;
   if ((err = emu10k1_midi_init(emu, midi, 0, Audigy MPU-401 (UART)))  0)
    return err;

   midi-tx_enable = INTE_MIDITXENABLE;
   midi-rx_enable = INTE_MIDIRXENABLE;
   midi-port = A_MUDATA1;
   midi-ipr_tx = IPR_MIDITRANSBUFEMPTY;
   midi-ipr_rx = IPR_MIDIRECVBUFEMPTY;
   midi-interrupt = snd_emu10k1_midi_interrupt;

   midi = emu-midi2;
   if ((err = emu10k1_midi_init(emu, midi, 1, Audigy MPU-401 #2))  0)
    return err;

   midi-tx_enable = INTE_A_MIDITXENABLE2;
   midi-rx_enable = INTE_A_MIDIRXENABLE2;
   midi-port = A_MUDATA2;
   midi-ipr_tx = IPR_A_MIDITRANSBUFEMPTY2;
   midi-ipr_rx = IPR_A_MIDIRECVBUFEMPTY2;
   midi-interrupt = snd_emu10k1_midi_interrupt2;

   /*** NEW CODE ***  Pulse reset line for the second UART */

   val = inl(emu-port + A_IOCFG);
   outl (val | A_IOCFG_GPOUT2, emu-port + A_IOCFG);
   udelay(10);  /* udelay is a bad kludge, but remember that this is 
called only once on startup */
   outl (val, emu-port + A_IOCFG);

   return 0;
  }

  I suspect that my use of udelay would make a real kernel hacker
  cringe, but the level of GPOUT2 needs to remain high for a few
  microseconds to provide a stable RESET signal.

  Anyway, this fixes the problem. I have applied the patch for pretty much 
every major upgrade of the kernel. It is sufficient to compile the module 
snd-emu10k1.ko and replace it in the module tree.
  --- 
  ApportVersion: 2.14.1-0ubuntu3.2
  Architecture: amd64
  AudioDevicesInUse:
   USERPID ACCESS COMMAND
   /dev/snd/controlC2:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC1:  mhaidekk   2321 F pulseaudio
   /dev/snd/controlC0:  mhaidekk   2321 F pulseaudio
  CRDA: Error: [Errno 2] No such file or directory
  CurrentDesktop: KDE
  DistroRelease: Ubuntu 14.04
  EcryptfsInUse: Yes
  HibernationDevice: RESUME=UUID=b15a827a-7aa7-4add-a9b4-cb68262cfddd
  InstallationDate: Installed on 2013-12-31 (161 days ago)
  InstallationMedia: Kubuntu 12.04.3 LTS Precise Pangolin - Release amd64 
(20130822)
  IwConfig:
   eth1  no wireless extensions.
   
   lono wireless extensions.
  MachineType: BIOSTAR Group TA970
  NonfreeKernelModules: fglrx
  Package: linux (not installed)
  ProcFB: 0 VESA VGA
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.13.0-29-generic 
root=UUID=11a18cc0-0c2e-4ce8-9acd-44c5bb8820e2 ro
  ProcVersionSignature: Ubuntu 3.13.0-29.53-generic 3.13.11.2
  RelatedPackageVersions:
   linux-restricted-modules-3.13.0-29-generic N/A
   linux-backports-modules-3.13.0-29-generic  N/A
   linux-firmware 1.127.2
  RfKill:
   
  Tags:  trusty
  Uname: Linux 3.13.0-29-generic x86_64
  UpgradeStatus: Upgraded to trusty on 2014-06-07 (3 days ago)
  UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
  _MarkForUpload: True
  dmi.bios.date: 01/14/2013
  dmi.bios.vendor: American Megatrends Inc.
  dmi.bios.version: 4.6.4
  dmi.board.asset.tag: None
  dmi.board.name: TA970
  dmi.board.vendor: BIOSTAR Group