提交 52cb6a20 编写于 作者: G Greg Kroah-Hartman

Merge tag 'extcon-next-for-3.14' of...

Merge tag 'extcon-next-for-3.14' of git://git.kernel.org/pub/scm/linux/kernel/git/chanwoo/extcon into char-misc-next

Chanwoo writes:

Update extcon for v3.14

This patchset add new driver of extcon-max14577.c which detect various external
connector and fix minor issue of extcon provider driver(extcon-arizona/palams/
gpio.c). Also, update documentation of previous 'switch' porting guide and
extcon git repository url.

Detailed description for patchset:
- New driver of extcon-max14577.c
: Add extcon-max14577.c drvier to support Maxim MUIC(Micro USB Interface
Controller) which detect USB/TA/JIG/AUDIO-DOCK and additional accessory
according to each resistance when connected external connector.

- extcon-arizoan.c driver
: Code clean to use define macro instead of hex value
: Fix minor issue to reset back to our staring state
: Fix race with microphone detection and removal

- extcon-palmas.c driver
: Fix minor issue and renaming compatible string of Devicetree

- extcon-gpio.c driver
: Fix bug about ordering initialization of gpio pin on probe()
: Send uevent after wakeup from suspend state because some SoC
  haven't wakeup interrupt on suspend state.

- Documentation (Documentation/extcon/porting-android-switch-class)
: Fix switch class porting guide

- Update extcon git repository url
...@@ -2,7 +2,11 @@ EXTCON FOR PALMAS/TWL CHIPS ...@@ -2,7 +2,11 @@ EXTCON FOR PALMAS/TWL CHIPS
PALMAS USB COMPARATOR PALMAS USB COMPARATOR
Required Properties: Required Properties:
- compatible : Should be "ti,palmas-usb" or "ti,twl6035-usb" - compatible: should contain one of:
* "ti,palmas-usb-vid".
* "ti,twl6035-usb-vid".
* "ti,palmas-usb" (DEPRECATED - use "ti,palmas-usb-vid").
* "ti,twl6035-usb" (DEPRECATED - use "ti,twl6035-usb-vid").
Optional Properties: Optional Properties:
- ti,wakeup : To enable the wakeup comparator in probe - ti,wakeup : To enable the wakeup comparator in probe
......
...@@ -50,7 +50,7 @@ so that they are still compatible with legacy userspace processes. ...@@ -50,7 +50,7 @@ so that they are still compatible with legacy userspace processes.
Extcon's extended features for switch device drivers with Extcon's extended features for switch device drivers with
complex features usually required magic numbers in state complex features usually required magic numbers in state
value of switch_dev. With extcon, such magic numbers that value of switch_dev. With extcon, such magic numbers that
support multiple cables ( support multiple cables are no more required or supported.
1. Define cable names at edev->supported_cable. 1. Define cable names at edev->supported_cable.
2. (Recommended) remove print_state callback. 2. (Recommended) remove print_state callback.
...@@ -114,11 +114,8 @@ exclusive, the two cables cannot be in ATTACHED state simulteneously. ...@@ -114,11 +114,8 @@ exclusive, the two cables cannot be in ATTACHED state simulteneously.
****** ABI Location ****** ABI Location
If "CONFIG_ANDROID" is enabled and "CONFIG_ANDROID_SWITCH" is If "CONFIG_ANDROID" is enabled, /sys/class/switch/* are created
disabled, /sys/class/switch/* are created as symbolic links to as symbolic links to /sys/class/extcon/*.
/sys/class/extcon/*. Because CONFIG_ANDROID_SWITCH creates
/sys/class/switch directory, we disable symboling linking if
CONFIG_ANDROID_SWITCH is enabled.
The two files of switch class, name and state, are provided with The two files of switch class, name and state, are provided with
extcon, too. When the multistate support (STEP 2 of CHAPTER 1.) is extcon, too. When the multistate support (STEP 2 of CHAPTER 1.) is
......
...@@ -3330,6 +3330,7 @@ EXTERNAL CONNECTOR SUBSYSTEM (EXTCON) ...@@ -3330,6 +3330,7 @@ EXTERNAL CONNECTOR SUBSYSTEM (EXTCON)
M: MyungJoo Ham <myungjoo.ham@samsung.com> M: MyungJoo Ham <myungjoo.ham@samsung.com>
M: Chanwoo Choi <cw00.choi@samsung.com> M: Chanwoo Choi <cw00.choi@samsung.com>
L: linux-kernel@vger.kernel.org L: linux-kernel@vger.kernel.org
T: git git://git.kernel.org/pub/scm/linux/kernel/git/chanwoo/extcon.git
S: Maintained S: Maintained
F: drivers/extcon/ F: drivers/extcon/
F: Documentation/extcon/ F: Documentation/extcon/
......
...@@ -31,6 +31,16 @@ config EXTCON_ADC_JACK ...@@ -31,6 +31,16 @@ config EXTCON_ADC_JACK
help help
Say Y here to enable extcon device driver based on ADC values. Say Y here to enable extcon device driver based on ADC values.
config EXTCON_MAX14577
tristate "MAX14577 EXTCON Support"
depends on MFD_MAX14577
select IRQ_DOMAIN
select REGMAP_I2C
help
If you say yes here you get support for the MUIC device of
Maxim MAX14577 PMIC. The MAX14577 MUIC is a USB port accessory
detector and switch.
config EXTCON_MAX77693 config EXTCON_MAX77693
tristate "MAX77693 EXTCON Support" tristate "MAX77693 EXTCON Support"
depends on MFD_MAX77693 && INPUT depends on MFD_MAX77693 && INPUT
......
...@@ -7,6 +7,7 @@ obj-$(CONFIG_OF_EXTCON) += of_extcon.o ...@@ -7,6 +7,7 @@ obj-$(CONFIG_OF_EXTCON) += of_extcon.o
obj-$(CONFIG_EXTCON) += extcon-class.o obj-$(CONFIG_EXTCON) += extcon-class.o
obj-$(CONFIG_EXTCON_GPIO) += extcon-gpio.o obj-$(CONFIG_EXTCON_GPIO) += extcon-gpio.o
obj-$(CONFIG_EXTCON_ADC_JACK) += extcon-adc-jack.o obj-$(CONFIG_EXTCON_ADC_JACK) += extcon-adc-jack.o
obj-$(CONFIG_EXTCON_MAX14577) += extcon-max14577.o
obj-$(CONFIG_EXTCON_MAX77693) += extcon-max77693.o obj-$(CONFIG_EXTCON_MAX77693) += extcon-max77693.o
obj-$(CONFIG_EXTCON_MAX8997) += extcon-max8997.o obj-$(CONFIG_EXTCON_MAX8997) += extcon-max8997.o
obj-$(CONFIG_EXTCON_ARIZONA) += extcon-arizona.o obj-$(CONFIG_EXTCON_ARIZONA) += extcon-arizona.o
......
...@@ -44,6 +44,15 @@ ...@@ -44,6 +44,15 @@
#define HPDET_DEBOUNCE 500 #define HPDET_DEBOUNCE 500
#define DEFAULT_MICD_TIMEOUT 2000 #define DEFAULT_MICD_TIMEOUT 2000
#define MICD_LVL_1_TO_7 (ARIZONA_MICD_LVL_1 | ARIZONA_MICD_LVL_2 | \
ARIZONA_MICD_LVL_3 | ARIZONA_MICD_LVL_4 | \
ARIZONA_MICD_LVL_5 | ARIZONA_MICD_LVL_6 | \
ARIZONA_MICD_LVL_7)
#define MICD_LVL_0_TO_7 (ARIZONA_MICD_LVL_0 | MICD_LVL_1_TO_7)
#define MICD_LVL_0_TO_8 (MICD_LVL_0_TO_7 | ARIZONA_MICD_LVL_8)
struct arizona_extcon_info { struct arizona_extcon_info {
struct device *dev; struct device *dev;
struct arizona *arizona; struct arizona *arizona;
...@@ -426,26 +435,15 @@ static int arizona_hpdet_read(struct arizona_extcon_info *info) ...@@ -426,26 +435,15 @@ static int arizona_hpdet_read(struct arizona_extcon_info *info)
} }
val &= ARIZONA_HP_LVL_B_MASK; val &= ARIZONA_HP_LVL_B_MASK;
/* Convert to ohms, the value is in 0.5 ohm increments */
val /= 2;
regmap_read(arizona->regmap, ARIZONA_HEADPHONE_DETECT_1, regmap_read(arizona->regmap, ARIZONA_HEADPHONE_DETECT_1,
&range); &range);
range = (range & ARIZONA_HP_IMPEDANCE_RANGE_MASK) range = (range & ARIZONA_HP_IMPEDANCE_RANGE_MASK)
>> ARIZONA_HP_IMPEDANCE_RANGE_SHIFT; >> ARIZONA_HP_IMPEDANCE_RANGE_SHIFT;
/* Skip up or down a range? */ /* Skip up a range, or report? */
if (range && (val < arizona_hpdet_c_ranges[range].min)) {
range--;
dev_dbg(arizona->dev, "Moving to HPDET range %d-%d\n",
arizona_hpdet_c_ranges[range].min,
arizona_hpdet_c_ranges[range].max);
regmap_update_bits(arizona->regmap,
ARIZONA_HEADPHONE_DETECT_1,
ARIZONA_HP_IMPEDANCE_RANGE_MASK,
range <<
ARIZONA_HP_IMPEDANCE_RANGE_SHIFT);
return -EAGAIN;
}
if (range < ARRAY_SIZE(arizona_hpdet_c_ranges) - 1 && if (range < ARRAY_SIZE(arizona_hpdet_c_ranges) - 1 &&
(val >= arizona_hpdet_c_ranges[range].max)) { (val >= arizona_hpdet_c_ranges[range].max)) {
range++; range++;
...@@ -459,6 +457,12 @@ static int arizona_hpdet_read(struct arizona_extcon_info *info) ...@@ -459,6 +457,12 @@ static int arizona_hpdet_read(struct arizona_extcon_info *info)
ARIZONA_HP_IMPEDANCE_RANGE_SHIFT); ARIZONA_HP_IMPEDANCE_RANGE_SHIFT);
return -EAGAIN; return -EAGAIN;
} }
if (range && (val < arizona_hpdet_c_ranges[range].min)) {
dev_dbg(arizona->dev, "Reporting range boundary %d\n",
arizona_hpdet_c_ranges[range].min);
val = arizona_hpdet_c_ranges[range].min;
}
} }
dev_dbg(arizona->dev, "HP impedance %d ohms\n", val); dev_dbg(arizona->dev, "HP impedance %d ohms\n", val);
...@@ -594,9 +598,15 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data) ...@@ -594,9 +598,15 @@ static irqreturn_t arizona_hpdet_irq(int irq, void *data)
dev_err(arizona->dev, "Failed to report HP/line: %d\n", dev_err(arizona->dev, "Failed to report HP/line: %d\n",
ret); ret);
done:
/* Reset back to starting range */
regmap_update_bits(arizona->regmap,
ARIZONA_HEADPHONE_DETECT_1,
ARIZONA_HP_IMPEDANCE_RANGE_MASK | ARIZONA_HP_POLL,
0);
arizona_extcon_do_magic(info, 0); arizona_extcon_do_magic(info, 0);
done:
if (id_gpio) if (id_gpio)
gpio_set_value_cansleep(id_gpio, 0); gpio_set_value_cansleep(id_gpio, 0);
...@@ -765,7 +775,20 @@ static void arizona_micd_detect(struct work_struct *work) ...@@ -765,7 +775,20 @@ static void arizona_micd_detect(struct work_struct *work)
mutex_lock(&info->lock); mutex_lock(&info->lock);
for (i = 0; i < 10 && !(val & 0x7fc); i++) { /* If the cable was removed while measuring ignore the result */
ret = extcon_get_cable_state_(&info->edev, ARIZONA_CABLE_MECHANICAL);
if (ret < 0) {
dev_err(arizona->dev, "Failed to check cable state: %d\n",
ret);
mutex_unlock(&info->lock);
return;
} else if (!ret) {
dev_dbg(arizona->dev, "Ignoring MICDET for removed cable\n");
mutex_unlock(&info->lock);
return;
}
for (i = 0; i < 10 && !(val & MICD_LVL_0_TO_8); i++) {
ret = regmap_read(arizona->regmap, ARIZONA_MIC_DETECT_3, &val); ret = regmap_read(arizona->regmap, ARIZONA_MIC_DETECT_3, &val);
if (ret != 0) { if (ret != 0) {
dev_err(arizona->dev, dev_err(arizona->dev,
...@@ -784,7 +807,7 @@ static void arizona_micd_detect(struct work_struct *work) ...@@ -784,7 +807,7 @@ static void arizona_micd_detect(struct work_struct *work)
} }
} }
if (i == 10 && !(val & 0x7fc)) { if (i == 10 && !(val & MICD_LVL_0_TO_8)) {
dev_err(arizona->dev, "Failed to get valid MICDET value\n"); dev_err(arizona->dev, "Failed to get valid MICDET value\n");
mutex_unlock(&info->lock); mutex_unlock(&info->lock);
return; return;
...@@ -798,7 +821,7 @@ static void arizona_micd_detect(struct work_struct *work) ...@@ -798,7 +821,7 @@ static void arizona_micd_detect(struct work_struct *work)
} }
/* If we got a high impedence we should have a headset, report it. */ /* If we got a high impedence we should have a headset, report it. */
if (info->detecting && (val & 0x400)) { if (info->detecting && (val & ARIZONA_MICD_LVL_8)) {
arizona_identify_headphone(info); arizona_identify_headphone(info);
ret = extcon_update_state(&info->edev, ret = extcon_update_state(&info->edev,
...@@ -827,7 +850,7 @@ static void arizona_micd_detect(struct work_struct *work) ...@@ -827,7 +850,7 @@ static void arizona_micd_detect(struct work_struct *work)
* plain headphones. If both polarities report a low * plain headphones. If both polarities report a low
* impedence then give up and report headphones. * impedence then give up and report headphones.
*/ */
if (info->detecting && (val & 0x3f8)) { if (info->detecting && (val & MICD_LVL_1_TO_7)) {
if (info->jack_flips >= info->micd_num_modes * 10) { if (info->jack_flips >= info->micd_num_modes * 10) {
dev_dbg(arizona->dev, "Detected HP/line\n"); dev_dbg(arizona->dev, "Detected HP/line\n");
arizona_identify_headphone(info); arizona_identify_headphone(info);
...@@ -851,7 +874,7 @@ static void arizona_micd_detect(struct work_struct *work) ...@@ -851,7 +874,7 @@ static void arizona_micd_detect(struct work_struct *work)
* If we're still detecting and we detect a short then we've * If we're still detecting and we detect a short then we've
* got a headphone. Otherwise it's a button press. * got a headphone. Otherwise it's a button press.
*/ */
if (val & 0x3fc) { if (val & MICD_LVL_0_TO_7) {
if (info->mic) { if (info->mic) {
dev_dbg(arizona->dev, "Mic button detected\n"); dev_dbg(arizona->dev, "Mic button detected\n");
...@@ -1126,6 +1149,16 @@ static int arizona_extcon_probe(struct platform_device *pdev) ...@@ -1126,6 +1149,16 @@ static int arizona_extcon_probe(struct platform_device *pdev)
break; break;
} }
break; break;
case WM5110:
switch (arizona->rev) {
case 0 ... 2:
break;
default:
info->micd_clamp = true;
info->hpdet_ip = 2;
break;
}
break;
default: default:
break; break;
} }
......
...@@ -40,6 +40,7 @@ struct gpio_extcon_data { ...@@ -40,6 +40,7 @@ struct gpio_extcon_data {
int irq; int irq;
struct delayed_work work; struct delayed_work work;
unsigned long debounce_jiffies; unsigned long debounce_jiffies;
bool check_on_resume;
}; };
static void gpio_extcon_work(struct work_struct *work) static void gpio_extcon_work(struct work_struct *work)
...@@ -103,8 +104,15 @@ static int gpio_extcon_probe(struct platform_device *pdev) ...@@ -103,8 +104,15 @@ static int gpio_extcon_probe(struct platform_device *pdev)
extcon_data->gpio_active_low = pdata->gpio_active_low; extcon_data->gpio_active_low = pdata->gpio_active_low;
extcon_data->state_on = pdata->state_on; extcon_data->state_on = pdata->state_on;
extcon_data->state_off = pdata->state_off; extcon_data->state_off = pdata->state_off;
extcon_data->check_on_resume = pdata->check_on_resume;
if (pdata->state_on && pdata->state_off) if (pdata->state_on && pdata->state_off)
extcon_data->edev.print_state = extcon_gpio_print_state; extcon_data->edev.print_state = extcon_gpio_print_state;
ret = devm_gpio_request_one(&pdev->dev, extcon_data->gpio, GPIOF_DIR_IN,
pdev->name);
if (ret < 0)
return ret;
if (pdata->debounce) { if (pdata->debounce) {
ret = gpio_set_debounce(extcon_data->gpio, ret = gpio_set_debounce(extcon_data->gpio,
pdata->debounce * 1000); pdata->debounce * 1000);
...@@ -117,11 +125,6 @@ static int gpio_extcon_probe(struct platform_device *pdev) ...@@ -117,11 +125,6 @@ static int gpio_extcon_probe(struct platform_device *pdev)
if (ret < 0) if (ret < 0)
return ret; return ret;
ret = devm_gpio_request_one(&pdev->dev, extcon_data->gpio, GPIOF_DIR_IN,
pdev->name);
if (ret < 0)
goto err;
INIT_DELAYED_WORK(&extcon_data->work, gpio_extcon_work); INIT_DELAYED_WORK(&extcon_data->work, gpio_extcon_work);
extcon_data->irq = gpio_to_irq(extcon_data->gpio); extcon_data->irq = gpio_to_irq(extcon_data->gpio);
...@@ -159,12 +162,31 @@ static int gpio_extcon_remove(struct platform_device *pdev) ...@@ -159,12 +162,31 @@ static int gpio_extcon_remove(struct platform_device *pdev)
return 0; return 0;
} }
#ifdef CONFIG_PM_SLEEP
static int gpio_extcon_resume(struct device *dev)
{
struct gpio_extcon_data *extcon_data;
extcon_data = dev_get_drvdata(dev);
if (extcon_data->check_on_resume)
queue_delayed_work(system_power_efficient_wq,
&extcon_data->work, extcon_data->debounce_jiffies);
return 0;
}
#endif
static const struct dev_pm_ops gpio_extcon_pm_ops = {
SET_SYSTEM_SLEEP_PM_OPS(NULL, gpio_extcon_resume)
};
static struct platform_driver gpio_extcon_driver = { static struct platform_driver gpio_extcon_driver = {
.probe = gpio_extcon_probe, .probe = gpio_extcon_probe,
.remove = gpio_extcon_remove, .remove = gpio_extcon_remove,
.driver = { .driver = {
.name = "extcon-gpio", .name = "extcon-gpio",
.owner = THIS_MODULE, .owner = THIS_MODULE,
.pm = &gpio_extcon_pm_ops,
}, },
}; };
......
此差异已折叠。
...@@ -78,20 +78,24 @@ static irqreturn_t palmas_vbus_irq_handler(int irq, void *_palmas_usb) ...@@ -78,20 +78,24 @@ static irqreturn_t palmas_vbus_irq_handler(int irq, void *_palmas_usb)
static irqreturn_t palmas_id_irq_handler(int irq, void *_palmas_usb) static irqreturn_t palmas_id_irq_handler(int irq, void *_palmas_usb)
{ {
unsigned int set; unsigned int set, id_src;
struct palmas_usb *palmas_usb = _palmas_usb; struct palmas_usb *palmas_usb = _palmas_usb;
palmas_read(palmas_usb->palmas, PALMAS_USB_OTG_BASE, palmas_read(palmas_usb->palmas, PALMAS_USB_OTG_BASE,
PALMAS_USB_ID_INT_LATCH_SET, &set); PALMAS_USB_ID_INT_LATCH_SET, &set);
palmas_read(palmas_usb->palmas, PALMAS_USB_OTG_BASE,
PALMAS_USB_ID_INT_SRC, &id_src);
if (set & PALMAS_USB_ID_INT_SRC_ID_GND) { if ((set & PALMAS_USB_ID_INT_SRC_ID_GND) &&
(id_src & PALMAS_USB_ID_INT_SRC_ID_GND)) {
palmas_write(palmas_usb->palmas, PALMAS_USB_OTG_BASE, palmas_write(palmas_usb->palmas, PALMAS_USB_OTG_BASE,
PALMAS_USB_ID_INT_LATCH_CLR, PALMAS_USB_ID_INT_LATCH_CLR,
PALMAS_USB_ID_INT_EN_HI_CLR_ID_GND); PALMAS_USB_ID_INT_EN_HI_CLR_ID_GND);
palmas_usb->linkstat = PALMAS_USB_STATE_ID; palmas_usb->linkstat = PALMAS_USB_STATE_ID;
extcon_set_cable_state(&palmas_usb->edev, "USB-HOST", true); extcon_set_cable_state(&palmas_usb->edev, "USB-HOST", true);
dev_info(palmas_usb->dev, "USB-HOST cable is attached\n"); dev_info(palmas_usb->dev, "USB-HOST cable is attached\n");
} else if (set & PALMAS_USB_ID_INT_SRC_ID_FLOAT) { } else if ((set & PALMAS_USB_ID_INT_SRC_ID_FLOAT) &&
(id_src & PALMAS_USB_ID_INT_SRC_ID_FLOAT)) {
palmas_write(palmas_usb->palmas, PALMAS_USB_OTG_BASE, palmas_write(palmas_usb->palmas, PALMAS_USB_OTG_BASE,
PALMAS_USB_ID_INT_LATCH_CLR, PALMAS_USB_ID_INT_LATCH_CLR,
PALMAS_USB_ID_INT_EN_HI_CLR_ID_FLOAT); PALMAS_USB_ID_INT_EN_HI_CLR_ID_FLOAT);
...@@ -103,6 +107,11 @@ static irqreturn_t palmas_id_irq_handler(int irq, void *_palmas_usb) ...@@ -103,6 +107,11 @@ static irqreturn_t palmas_id_irq_handler(int irq, void *_palmas_usb)
palmas_usb->linkstat = PALMAS_USB_STATE_DISCONNECT; palmas_usb->linkstat = PALMAS_USB_STATE_DISCONNECT;
extcon_set_cable_state(&palmas_usb->edev, "USB-HOST", false); extcon_set_cable_state(&palmas_usb->edev, "USB-HOST", false);
dev_info(palmas_usb->dev, "USB-HOST cable is detached\n"); dev_info(palmas_usb->dev, "USB-HOST cable is detached\n");
} else if ((palmas_usb->linkstat == PALMAS_USB_STATE_DISCONNECT) &&
(id_src & PALMAS_USB_ID_INT_SRC_ID_GND)) {
palmas_usb->linkstat = PALMAS_USB_STATE_ID;
extcon_set_cable_state(&palmas_usb->edev, "USB-HOST", true);
dev_info(palmas_usb->dev, " USB-HOST cable is attached\n");
} }
return IRQ_HANDLED; return IRQ_HANDLED;
...@@ -269,7 +278,9 @@ static const struct dev_pm_ops palmas_pm_ops = { ...@@ -269,7 +278,9 @@ static const struct dev_pm_ops palmas_pm_ops = {
static struct of_device_id of_palmas_match_tbl[] = { static struct of_device_id of_palmas_match_tbl[] = {
{ .compatible = "ti,palmas-usb", }, { .compatible = "ti,palmas-usb", },
{ .compatible = "ti,palmas-usb-vid", },
{ .compatible = "ti,twl6035-usb", }, { .compatible = "ti,twl6035-usb", },
{ .compatible = "ti,twl6035-usb-vid", },
{ /* end */ } { /* end */ }
}; };
......
...@@ -51,6 +51,7 @@ struct gpio_extcon_platform_data { ...@@ -51,6 +51,7 @@ struct gpio_extcon_platform_data {
/* if NULL, "0" or "1" will be printed */ /* if NULL, "0" or "1" will be printed */
const char *state_on; const char *state_on;
const char *state_off; const char *state_off;
bool check_on_resume;
}; };
#endif /* __EXTCON_GPIO_H__ */ #endif /* __EXTCON_GPIO_H__ */
...@@ -2196,6 +2196,15 @@ ...@@ -2196,6 +2196,15 @@
/* /*
* R677 (0x2A5) - Mic Detect 3 * R677 (0x2A5) - Mic Detect 3
*/ */
#define ARIZONA_MICD_LVL_0 0x0004 /* MICD_LVL - [2] */
#define ARIZONA_MICD_LVL_1 0x0008 /* MICD_LVL - [3] */
#define ARIZONA_MICD_LVL_2 0x0010 /* MICD_LVL - [4] */
#define ARIZONA_MICD_LVL_3 0x0020 /* MICD_LVL - [5] */
#define ARIZONA_MICD_LVL_4 0x0040 /* MICD_LVL - [6] */
#define ARIZONA_MICD_LVL_5 0x0080 /* MICD_LVL - [7] */
#define ARIZONA_MICD_LVL_6 0x0100 /* MICD_LVL - [8] */
#define ARIZONA_MICD_LVL_7 0x0200 /* MICD_LVL - [9] */
#define ARIZONA_MICD_LVL_8 0x0400 /* MICD_LVL - [10] */
#define ARIZONA_MICD_LVL_MASK 0x07FC /* MICD_LVL - [10:2] */ #define ARIZONA_MICD_LVL_MASK 0x07FC /* MICD_LVL - [10:2] */
#define ARIZONA_MICD_LVL_SHIFT 2 /* MICD_LVL - [10:2] */ #define ARIZONA_MICD_LVL_SHIFT 2 /* MICD_LVL - [10:2] */
#define ARIZONA_MICD_LVL_WIDTH 9 /* MICD_LVL - [10:2] */ #define ARIZONA_MICD_LVL_WIDTH 9 /* MICD_LVL - [10:2] */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册