1. 10 5月, 2016 1 次提交
    • T
      ALSA: fireworks: drop reuse of incoming packet parameter for ougoing packet parameter · eb4a378f
      Takashi Sakamoto 提交于
      On Fireworks board module of Echo Audio, TSB43Cx43A (IceLynx Micro, iCEM)
      is used to process payload of isochronous packets. There's an public
      document of this chip[1]. This document is for firmware programmers to
      transfer/receive AMDTP with IEC60958 data format, however in clause 2.5,
      2.6 and 2.7, we can see system design to utilize the sequence of value in
      SYT field of CIP header. In clause 2.3, we can see the specification of
      Audio Master Clock (MCLK) from iCEM.
      
      Well, this clock is actually not used for sampling clock. This can be
      confirmed when corresponding driver transfer random value as the sequence
      of SYT field. Even if in this case, the unit generates proper sound.
      
      Additionally, in unique command set for this board module, the format
      of CIP is changed; for IEC 61883-6 mode which we use, and for Windows
      Operating System. In the latter mode, the whole 32 bit field in second CIP
      header from Windows driver is used to represent counter of packets (NO-DATA
      code is still used for packets without data blocks). If the master clock
      was physically used by DSP on the board module, the Windows driver must
      have transferred correct sequence of SYT field.
      
      Furthermore, as long as seeing capacities of AudioFire2, AudioFire4,
      AudioFire8, AudioFirePre8 and AudioFire12, these models don't support
      SYT-Match clock source.
      
      Summary, we have no need to relate incoming/outgoing packets. This commit
      drops reusing SYT sequence of incoming packets for outgoing packets.
      
      [1] Using TSB43Cx43A: S/PDIF over 1394 (2003, Texus Instruments
      Incorporated)
      http://www.ti.com/analog/docs/litabsmultiplefilelist.tsp?literatureNumber=slla148&docCategoryId=1&familyId=361Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      eb4a378f
  2. 31 3月, 2016 1 次提交
  3. 15 11月, 2015 1 次提交
  4. 29 9月, 2015 2 次提交
  5. 05 8月, 2015 2 次提交
    • T
      ALSA: fireworks/firewire-lib: add support for recent firmware quirk · 18f5ed36
      Takashi Sakamoto 提交于
      Fireworks uses TSB43CB43(IceLynx-Micro) as its IEC 61883-1/6 interface.
      This chip includes ARM7 core, and loads and runs program. The firmware
      is stored in on-board memory and loaded every powering-on from it.
      
      Echo Audio ships several versions of firmwares for each model. These
      firmwares have each quirk and the quirk changes a sequence of packets.
      
      As long as I investigated, AudioFire2/AudioFire4/AudioFirePre8 have a
      quirk to transfer a first packet with 0x02 in its dbc field. This causes
      ALSA Fireworks driver to detect discontinuity. In this case, firmware
      version 5.7.0, 5.7.3 and 5.8.0 are used.
      
      Payload  CIP      CIP
      quadlets header1  header2
      02       00050002 90ffffff <-
      42       0005000a 90013000
      42       00050012 90014400
      42       0005001a 90015800
      02       0005001a 90ffffff
      42       00050022 90019000
      42       0005002a 9001a400
      42       00050032 9001b800
      02       00050032 90ffffff
      42       0005003a 9001d000
      42       00050042 9001e400
      42       0005004a 9001f800
      02       0005004a 90ffffff
      (AudioFire2 with firmware version 5.7.)
      
      $ dmesg
      snd-fireworks fw1.0: Detect discontinuity of CIP: 00 02
      
      These models, AudioFire8 (since Jul 2009 ) and Gibson Robot Interface
      Pack series uses the same ARM binary as their firmware. Thus, this
      quirk may be observed among them.
      
      This commit adds a new member for AMDTP structure. This member represents
      the value of dbc field in a first AMDTP packet. Drivers can set it with
      a preferred value according to model's quirk.
      Tested-by: NJohannes Oertei <johannes.oertel@uni-due.de>
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      18f5ed36
    • T
      Revert "ALSA: fireworks: add support for AudioFire2 quirk" · c85523d1
      Takashi Sakamoto 提交于
      This reverts commit 9c6893e0.
      
      The fix is superseded by the next commit as a better implementation
      for supporting AudioFire2/AudioFire4/AudioFirePre8 quirks.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      c85523d1
  6. 27 7月, 2015 1 次提交
    • T
      ALSA: fireworks: add support for AudioFire2 quirk · 9c6893e0
      Takashi Sakamoto 提交于
      Fireworks uses TSB43CB43(IceLynx-Micro) as its IEC 61883-1/6 interface.
      This chip includes ARM7 core, and loads and runs program. The firmware
      is stored in on-board memory and loaded every powering-on.
      
      Echo Audio ships several versions of firmwares for each model. These
      firmwares have each quirk and the quirk changes a sequence of packets.
      
      AudioFire2 has a quirk to transfer a first packet with non-zero in
      its dbc field. This causes ALSA Fireworks driver to detect discontinuity.
      As long as I investigated, firmware 5.7, 5.7.6 and 5.8 have this quirk.
      
      This commit adds a support for the quirk to handle AudioFire2 packets.
      For safe, CIP_SKIP_INIT_DBC_CHECK is applied to all versions of
      AudioFire2's firmwares.
      
      02 00050002 90ffffff <-
      42 0005000a 90013000
      42 00050012 90014400
      42 0005001a 90015800
      02 0005001a 90ffffff
      42 00050022 90019000
      42 0005002a 9001a400
      42 00050032 9001b800
      02 00050032 90ffffff
      42 0005003a 9001d000
      42 00050042 9001e400
      42 0005004a 9001f800
      02 0005004a 90ffffff
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      9c6893e0
  7. 04 6月, 2014 1 次提交
  8. 27 5月, 2014 2 次提交
  9. 26 5月, 2014 10 次提交
    • T
      ALSA: fireworks: Add command/response functionality into hwdep interface · 555e8a8f
      Takashi Sakamoto 提交于
      This commit adds two functionality for hwdep interface, adds two parameters for
      this driver, add a node for proc interface.
      
      To receive responses from devices, this driver already allocate own callback
      into initial memory space in host controller. This means no one can allocate
      its own callback to the address. So this driver must give a way for user
      applications to receive responses.
      
      This commit adds a functionality to receive responses via hwdep interface. The
      application can receive responses to read from this interface. To achieve this,
      this commit adds a buffer to queue responses. The default size of this buffer is
      1024 bytes. This size can be changed to give preferrable size to
      'resp_buf_size' parameter for this driver. The application should notice rest
      of space in this buffer because this driver don't push responses when this
      buffer has no space.
      
      Additionaly, this commit adds a functionality to transmit commands via hwdep
      interface. The application can transmit commands to write into this interface.
      I note that the application can transmit one command at once, but can receive
      as many responses as possible untill the user-buffer is full.
      
      When using these interfaces, the application must keep maximum number of
      sequence number in command within the number in firewire.h because this driver
      uses this number to distinguish the response is against the command by the
      application or this driver.
      
      Usually responses against commands which the application transmits are pushed
      into this buffer. But to enable 'resp_buf_debug' parameter for this driver, all
      responses are pushed into the buffer. When using this mode, I reccomend to
      expand the size of buffer.
      
      Finally this commit adds a new node into proc interface to output status of the
      buffer.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      555e8a8f
    • T
      ALSA: fireworks: Add hwdep interface · 594ddced
      Takashi Sakamoto 提交于
      This interface is designed for mixer/control application. To use hwdep
      interface, the application can get information about firewire node, can
      lock/unlock kernel streaming and can get notification at starting/stopping
      kernel streaming.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      594ddced
    • T
      ALSA: fireworks: Add PCM interface · aa02bb6e
      Takashi Sakamoto 提交于
      This commit adds a functionality to capture/playback PCM samples.
      
      When AMDTP stream is already running for PCM or the source of clock is not
      internal, available sampling rate is limited at current one.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      aa02bb6e
    • T
      ALSA: fireworks: Add MIDI interface · a63d3ff1
      Takashi Sakamoto 提交于
      This commit adds a functionality to capture/playback MIDI messages.
      
      When no AMDTP streams are running, this driver starts AMDTP stream for MIDI
      stream at current sampling rate.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      a63d3ff1
    • T
      ALSA: fireworks: Add proc interface for debugging purpose · 6a22683e
      Takashi Sakamoto 提交于
      This commit adds proc interface to output infomation for debugging.
       - firmware information
       - sampling rate and clock source
       - physical metering (linear value)
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      6a22683e
    • T
      ALSA: fireworks/firewire-lib: Add a quirk for fixed interval of reported dbc · d9cd0065
      Takashi Sakamoto 提交于
      Fireworks firmware version 5.5 reports fix interval for dbc in each packet.
      
      For example, AudioFire4:
      CIP0     CIP1     Payload
      00070000 900484FF 72
      00070008 9004A8FF 72
      00070008 90FFFFFF 02
      00070010 9004D0FF 72
      00070018 9004C4FF 72
      00070020 9004E8FF 72
      00070020 90FFFFFF 02
      00070028 900410FE 72
      
      The interval of each dbc should be 16 except for empty packet but it's still 8.
      
      This commit adds a flag for this quirk and codes to refer to a fixed value.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      d9cd0065
    • T
      ALSA: fireworks/firewire-lib: Add a quirk for wrong dbs in tx packets · 69702239
      Takashi Sakamoto 提交于
      One of Fireworks firmware, named  as 'AudioFire9', seems to transmit
      packets with wrong value of dbs. It's always 0x11 but actual size of
      data block is different.
      
      This commit adds a flag for this quirk and some codes to calculate
      correct size.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      69702239
    • T
      ALSA: fireworks: Add connection and stream management · 315fd41f
      Takashi Sakamoto 提交于
      Fireworks manages connections by CMP and can transmit/receive AMDTP streams
      with a few quirks. This commit adds functionality to start/stop the streams.
      
      Major Fireworks products don't support 'SYT-Match' clock source mode, except
      for AudioFire12/8(till 2009 July) with firmware version 1.0. Already in
      previous commit, this driver don't support such old firmwares. So this commit
      adds support for non 'SYT-Match' clock source modes.
      
      I note that this driver has a short gap for MIDI streams when starting PCM
      stream. When AMDTP streams are running only for MIDI data and PCM data is
      going to be joined at different sampling rate, then AMDTP streams are
      stopped once and started again after changing sampling rate.
      
      Unfortunately, Fireworks is not fully compliant to IEC 61883-1/6. Some commits
      following to this commit add these quirks.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      315fd41f
    • T
      ALSA: fireworks: Add transaction and some commands · bde8a8f2
      Takashi Sakamoto 提交于
      Fireworks uses own command and response. This commit adds functionality to
      transact and adds some commands required for sound card instance and kernel
      streaming.
      
      There are two ways to deliver substance of this transaction:
      1.AV/C vendor dependent command for command/response
      2.Async transaction to specific addresses for command/response
      
      By way 1, I confirm AudioFire12 cannot correctly response to some commands with
      firmware version 5.0 or later. This is also confirmed by FFADO. So this driver
      implement way 2.
      
      The address for response gives an issue. When this driver allocate own callback
      function into the address, then no one can allocate its own callback function.
      This situation is not good for applications in user-land. This issue is solved
      in later commit.
      
      I note there is a command to change the address for response if the device
      supports. But this driver uses default value. So users should not execute this
      command as long as hoping this driver works correctly.
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      bde8a8f2
    • T
      ALSA: fireworks: Add skelton for Fireworks based devices · b5b04336
      Takashi Sakamoto 提交于
      This commit adds a new driver for devices based on Fireworks. This driver
      just creates/removes card instance according to callbacks.
      
      Fireworks is a board module which Echo Audio produced. This module
      consists of three chipsets:
       - Communication chipset for IEEE1394 PHY/Link and IEC 61883-1/6
       - DSP or/and FPGA for signal processing
       - Flash Memory to store firmwares
      
      Current supported devices:
       - Mackie Onyx 400F/1200F
       - Echo AudioFire12/8(until 2009 July)
       - Echo AudioFire2/4/Pre8/8(since 2009 July)
       - Echo Fireworks 8/HDMI
       - Gibson Robot Interface pack/GoldTop
      Signed-off-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
      Signed-off-by: NTakashi Iwai <tiwai@suse.de>
      b5b04336