Logo Search packages:      
Sourcecode: linux-fsl-imx51 version File versions  Download package

PMIC_STATUS pmic_audio_antipop_disable ( void   ) 

Disable the anti-pop circuitry.

Disable the use of the built-in anti-pop circuitry to prevent noise from being generated when an external audio device is inserted or removed from an audio plug.

Return values:
PMIC_SUCCESS If the anti-pop circuitry was successfully disabled.
PMIC_ERROR If the anti-pop circuitry could not be disabled.

Definition at line 1847 of file pmic_audio.c.

References pmic_write_reg(), and SET_BITS.

      const unsigned int reg_mask = SET_BITS(regAUDIO_RX_0, BIASSPEED, 1) |
          SET_BITS(regAUDIO_RX_0, BIASEN, 1);
      const unsigned int reg_write = SET_BITS(regAUDIO_RX_0, BIASSPEED, 1) |
          SET_BITS(regAUDIO_RX_0, BIASEN, 0);

      /* No critical section required here since we are not updating any
       * global data.

       * Antipop is disabled by setting BIASSPEED  = 0. BIASEN bit remains set
       * as only antipop needs to be disabled
      rc = pmic_write_reg(REG_AUDIO_RX_0, reg_write, reg_mask);

      return rc;

Generated by  Doxygen 1.6.0   Back to index