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

PMIC_STATUS pmic_tcled_disable ( t_funlight_bank  bank  ) 

This function disables tri-color LED.

Parameters:
bank Selected tri-color bank
Returns:
This function returns PMIC_SUCCESS if successful.

Definition at line 859 of file pmic_light.c.

References pmic_write_reg(), and suspend_flag.

Referenced by pmic_light_ioctl().

{
      unsigned int mask = 0;

      if (suspend_flag == 1) {
            return -EBUSY;
      }

      switch (bank) {
      case TCLED_FUN_BANK1:
            mask = MASK_BK1_FL;
            break;
      case TCLED_FUN_BANK2:
            mask = MASK_BK2_FL;
            break;
      case TCLED_FUN_BANK3:
            mask = MASK_BK3_FL;
            break;
      default:
            return PMIC_PARAMETER_ERROR;
      }

      CHECK_ERROR(pmic_write_reg(LREG_0, 0, mask));

      return PMIC_SUCCESS;
}


Generated by  Doxygen 1.6.0   Back to index