linux/drivers/mfd/sec-core.c
<<
>>
Prefs
   1/*
   2 * sec-core.c
   3 *
   4 * Copyright (c) 2012 Samsung Electronics Co., Ltd
   5 *              http://www.samsung.com


	
      

      
core.c redistri e it and/or modify itkup" value="">
core.c
core.c
core.c
1 2
3
1 4
i="puden> >
i="puden> >
i="puden> >
i="puden> >
i="puden> >
i="puden> >
i="puden> >
21ec-c#i="pude <ue=""> i="puden> >
i="puden> >
23ec-c#i="pude <ue=""> i="puden> >
i="puden> .c > .c
i="puden> .c > .c
i="puden> .c > .c
i="puden> >
code=rm>_celld="c1/1d/aref">rm>_cellec-c code=s5m8751_devsd="c1/1d/aref">s5m8751_devsec-c[] = {> 31ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m8751-pmic"kup" va,> 33ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m-chton>r"kup" va,> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m8751-codec"kup" va,>
code=rm>_celld="c1/1d/aref">rm>_cellec-c code=s5m8763_devsd="c1/1d/aref">s5m8763_devsec-c[] = {> 41ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m8763-pmic"kup" va,> 43ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m-rtc"kup" va,> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m-chton>r"kup" va,>
code=rm>_celld="c1/1d/aref">rm>_cellec-c code=s5m8767_devsd="c1/1d/aref">s5m8767_devsec-c[] = {> 51ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m8767-pmic"kup" va,> 53ec-crivers/mmmmmmmmm./span> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s5m-rtc"kup" va,>
code=rm>_celld="c1/1d/aref">rm>_cellec-c code=s2mps11_devsd="c1/1d/aref">s2mps11_devsec-c[] = {> code= namd="c1/1d/aref"> namec-cr= L3"> 3"s2mps11-pmic"kup" va,> 61ec-c}elue="">
63ec-cint code= _reg_readd="c1/1d/aref">s _reg_readec-c(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-c, code=u8d="c1/1d/aref">u8ec-c code=regd="c1/1d/aref">regec-c, code=deform"c1/1d/aref">defoec-c)lue="">
regmap_readec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c, code=regd="c1/1d/aref">regec-c, code=deform"c1/1d/aref">defoec-c)elue="">
code=EXPORT_SYMBOL_GPLrm"c1/1d/aref">EXPORT_SYMBOL_GPLec-c(/span> code=s _reg_readd="c1/1d/aref">s _reg_readec-c)elue="">
code= _bulk_readd="c1/1d/aref">s _bulk_readec-c(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-c, code=u8d="c1/1d/aref">u8ec-c code=regd="c1/1d/aref">regec-c, code=counorm"c1/1d/aref">counoec-c, code=u8d="c1/1d/aref">u8ec-c<*/span> code=bufd="c1/1d/aref">bufec-c)lue="">
71ec-crivers/mdiv cla/span> code=regmap_bulk_readd="c1/1d/aref">regmap_bulk_readec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c, code=regd="c1/1d/aref">regec-c, code=bufd="c1/1d/aref">bufec-c, code=counorm"c1/1d/aref">counoec-c)elue="">
732 code=EXPORT_SYMBOL_GPLrm"c1/1d/aref">EXPORT_SYMBOL_GPLec-c(/span> code=s _bulk_readd="c1/1d/aref">s _bulk_readec-c)elue="">
_reg_writmec-c(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-c, code=u8d="c1/1d/aref">u8ec-c code=regd="c1/1d/aref">regec-c, code=u8d="c1/1d/aref">u8ec-c code=ts" cd="c1/1d/aref">ts" cec-c)lue="">
code=regmap_writmd="c1/1d/aref">regmap_writmec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c, code=regd="c1/1d/aref">regec-c, code=ts" cd="c1/1d/aref">ts" cec-c)elue="">
code=EXPORT_SYMBOL_GPLrm"c1/1d/aref">EXPORT_SYMBOL_GPLec-c(/span> code=s _reg_writmd="c1/1d/aref"> _reg_writmec-c)elue="">
81ec-cint code= _bulk_writmd="c1/1d/aref"> _bulk_writmec-c(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-c, code=u8d="c1/1d/aref">u8ec-c code=regd="c1/1d/aref">regec-c, code=counorm"c1/1d/aref">counoec-c, code=u8d="c1/1d/aref">u8ec-c<*/span> code=bufd="c1/1d/aref">bufec-c)lue="">
83ec-crivers/mdiv cla/span> code=regmap_raw_writmd="c1/1d/aref">regmap_raw_writmec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c, code=regd="c1/1d/aref">regec-c, code=bufd="c1/1d/aref">bufec-c, code=counorm"c1/1d/aref">counoec-c)elue="">
EXPORT_SYMBOL_GPLec-c(/span> code=s _bulk_writmd="c1/1d/aref"> _bulk_writmec-c)elue="">
code= _reg_updatmd="c1/1d/aref"> _reg_updatmec-c(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-c, code=u8d="c1/1d/aref">u8ec-c code=regd="c1/1d/aref">regec-c, code=u8d="c1/1d/aref">u8ec-c code=ts"d="c1/1d/aref">ts"ec-c, code=u8d="c1/1d/aref">u8ec-c code=maskd="c1/1d/aref">raskec-c)lue="">
code=regmap_updatm_bitsd="c1/1d/aref">regmap_updatm_bitsec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c, code=regd="c1/1d/aref">regec-c, code=maskd="c1/1d/aref">raskec-c, code=ts"d="c1/1d/aref">ts"ec-c)elue="">
912 code=EXPORT_SYMBOL_GPLrm"c1/1d/aref">EXPORT_SYMBOL_GPLec-c(/span> code=s _reg_updatmd="c1/1d/aref"> _reg_updatmec-c)elue="">
93ec-cethod= struct code=regmap_configd="c1/1d/aref">regmap_configec-c code=s _regmap_configd="c1/1d/aref">s _regmap_configec-cr= {> code=reg_bitsd="c1/1d/aref">reg_bitsec-cr= 8,> code=ts"_bitsd="c1/1d/aref">ts"_bitsec-cr= 8,>
code= _pmic_probmd="c1/1d/aref"> _pmic_probmec-c(struct code=i2c_clienorm"c1/1d/aref">i2c_clienoec-cr*/span> code=i2crm"c1/1d/aref">i2cec-c,lue="">
code=i2c_device_idd="c1/1d/aref">i2c_device_idec-cr*/span> code=idd="c1/1d/aref">idec-c)lue="">
code=s _platresu_datad="c1/1d/aref"> _platresu_dataec-cr*/span> code=pdatad="c1/1d/aref">pdataec-cr= code=i2crm"c1/1d/aref">i2cec-c-o_se/span> code=devd="c1/1d/aref">devec-c./span> code=platresu_datad="c1/1d/aref">platresu_dataec-celue="">
code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-celue="">
code=reorm"c1/1d/aref">reoec-celue="">
code=s _pmicd="c1/1d/aref">s _pmicec-cr= code=devm_kzallocd="c1/1d/aref">devm_kzallocec-c(&e/span> code=i2crm"c1/1d/aref">i2cec-c-o_se/span> code=devd="c1/1d/aref">devec-c, sizeof(struct code=s _pmic_devd="c1/1d/aref">s _pmic_devec-c),lue="">
code=GFP_KERNELrm"c1/1d/aref">GFP_KERNELec-c)elue="">
code=s _pmicd="c1/1d/aref">s _pmicec-c == code=NULLrm"c1/1d/aref">NULLec-c)lue="">
code=ENOMEMrm"c1/1d/aref">ENOMEMec-celue="">
code=i2c_set_clienodatad="c1/1d/aref">i2c_set_clienodataec-c(/span> code=i2crm"c1/1d/aref">i2cec-c,m/span> code=s _pmicd="c1/1d/aref">s _pmicec-c)elue="">
code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-cr=<&e/span> code=i2crm"c1/1d/aref">i2cec-c-o_se/span> code=devd="c1/1d/aref">devec-celue="">
code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=i2crm"c1/1d/aref">i2cec-cr= code=i2crm"c1/1d/aref">i2cec-celue="">
113ec-crivers/m/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=irqrm"c1/1d/aref">irqec-cr= code=i2crm"c1/1d/aref">i2cec-c-o_se/span> code=irqrm"c1/1d/aref">irqec-celue="">
s _pmicec-c-o_se/span> code=">"> code=idd="c1/1d/aref">idec-c-o_se/span> code=d d
code=pdatad="c1/1d/aref">pdataec-c) {> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=device_">device_"> code=pdatad="c1/1d/aref">pdataec-c-o_se/span> code=device_">device_">
code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=onod="c1/1d/aref">onoec-cr= code=pdatad="c1/1d/aref">pdataec-c-o_se/span> code=onod="c1/1d/aref">onoec-celue="">
code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=irq_bas/d="c1/1d/aref">irq_bas/ec-cr= code=pdatad="c1/1d/aref">pdataec-c-o_se/span> code=irq_bas/d="c1/1d/aref">irq_bas/ec-celue="">
code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=wakeupd="c1/1d/aref">wakeupec-cr= code=pdatad="c1/1d/aref">pdataec-c-o_se/span> code=wakeupd="c1/1d/aref">wakeupec-celue="">
121ec-crivers/m}lue="">
123ec-crivers/m/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-cr= code=devm_regmap_init_i2crm"c1/1d/aref">devm_regmap_init_i2cec-c(/span> code=i2crm"c1/1d/aref">i2cec-c,m&e/span> code=s _regmap_configd="c1/1d/aref">s _regmap_configec-c)elue="">
IS_ERRec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c)) {> code=reorm"c1/1d/aref">reoec-cr= code=PTR_ERRd="c1/1d/aref">PTR_ERRec-c(/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=regmapd="c1/1d/aref">regmapec-c)elue="">
code=dev_errrm"c1/1d/aref">dev_errec-c(&e/span> code=i2crm"c1/1d/aref">i2cec-c-o_se/span> code=devd="c1/1d/aref">devec-c, L3"> 3"Failed to allocate register map: %d\n"kup" va,> code=reorm"c1/1d/aref">reoec-c)elue="">
rype="hidd12en" 1s12-crivers/mmmmmmmmmdiv cla-psan> code=reorm"c1/1d/aref">reoec-celue="">
3113-crivers/m/span> code=s _pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devrt"c1/1d/aref">s rt"cr= code=i2crm"_new_dummyc1/1d/aref">i2c_setnew_dummyc(/span> code=i2crm"c1/1d/aref">i2cec-c,m&se/span> code=devadap mac1/1d/aref">i2cadap mac,m/span> code=s RTC_I2C_ADD"c1/1d/aref">PTRRTC_I2C_ADD"c)elue="">
code=s _set_clienodatad="c1/1d/aref">i2c_set_clienodataec-c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devrt"c1/1d/aref">s rt"cr= code=s _pmicd="c1/1d/aref">s _pmicec-c)elue="">
3313/alue="">
pdataec-cr= code=pdatad="c1/1d/aref">pdataec-c-o_se/span> code=wakcfgic_devrm"c1/1d/aref">irqcfgic_devrm"c)lue="">
pdataec-c-o_se/span> code=wakcfgic_devrm"c1/1d/aref">irqcfgic_devrm"c)lu(ue="">
code=s _pmi_bast_i2c1/1d/aref">s _pmi_bast_i2c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_ue="">
code=s runtime.het_clikup"v"c1/1d/aref">irqruntime.het_clikup"v"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, Lue="">
411c-crivers/mmmmswitchspan> code=s _pmicd="c1/1d/aref">s _pmicec-c ==se/span> code=device_">device_"> code=s S5M1-coXc1/1d/aref">devS5M1-coXcriv:a href="drivers/mfd/sec-core.c#12anc id="LL41" class="line" name="4L41"> 431c-crivers/mmmmmmmmm./san> code=reorm"c1/1d/aref">reoec-cr= code=PTR_celaddvice_id"c1/1d/aref">ts"_celaddvice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, L, -1span> code=s _751_devsd="c1/1d/aref">s5m8751_devsec-c[] code=s ARRAY_SIZEc1/1d/aref">s5mARRAY_SIZEc(/span> code=i2c_751_devsd="c1/1d/aref">s5m8751_devsec-c[] )span> code=s Lrm"c1/1d/aref">NULLec-c)lu, 0span> code=s Lrm"c1/1d/aref">NULLec-c)luue="">
casepan> code=s S5M1-63Xc1/1d/aref">devS5M1-63Xcriv:a href="drivers/mfd/sec-core.c#12anc fals37;1"> code=s rm"c1/1d/aref">reoec-cr= code=PTR_celaddvice_id"c1/1d/aref">ts"_celaddvice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, L, -1span> code=s _751_devsd="c1/1d/aref">s5m8763_devsec-c[] code=s ARRAY_SIZEc1/1d/aref">s5mARRAY_SIZEc(/span> code=i2c_751_devsd="c1/1d/aref">s5m8763_devsec-c[] )span> code=s Lrm"c1/1d/aref">NULLec-c)lu, 0span> code=s Lrm"c1/1d/aref">NULLec-c)luue="">
casepan> code=s S5M1-67Xc1/1d/aref">devS5M1-67Xcriv:a href="drivers/mfd/sec-core.c#12an" id="5L21" class="line" name="5L21"> 511c-crivers/mmmmmmmmm./san> code=s rm"c1/1d/aref">reoec-cr= code=PTR_celaddvice_id"c1/1d/aref">ts"_celaddvice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, L, -1span> code=s _751_devsd="c1/1d/aref">s5m8767_devsec-c[] code=s ARRAY_SIZEc1/1d/aref">s5mARRAY_SIZEc(/span> code=i2c_751_devsd="c1/1d/aref">s5m8767_devsec-c[] )span> code=s Lrm"c1/1d/aref">NULLec-c)lu, 0span> code=s Lrm"c1/1d/aref">NULLec-c)luue="">
531c-crivers/mmmmmmmmm./sbreake="">
devS2MPS1oXcriv:a href="drivers/mfd/sec-core.c#12an" reoec-cr= code=PTR_celaddvice_id"c1/1d/aref">ts"_celaddvice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, L, -1span> code=s _s11_devsd="c1/1d/aref">s2mps11_devsec-c[] code=s ARRAY_SIZEc1/1d/aref">s5mARRAY_SIZEc(/span> code=i2c_s11_devsd="c1/1d/aref">s2mps11_devsec-c[] )span> code=s Lrm"c1/1d/aref">NULLec-c)lu, 0span> code=s Lrm"c1/1d/aref">NULLec-c)luue="">
default:a href="drivers/mfd/sec-core.c#12an" fals39;1"> * s Ihe is happense Libmec- funup" v prograblemkup" value="">
code=s BUGc1/1d/aref">NULBUGc)lu(ue="">
6116-crivers/m}lue="">
6316-crivers/mint code=IS_rm"c1/1d/aref">reoec-cr=
devec-c(&ae="">
code=reorm"c1/1d/aref">reoec-celue="">
code=s rm"c1/1d/aref">devec-c(&a:a href="drivers/mfd/sec-core.c#12ann fals69;1"> code=s _celremovevice_id"c1/1d/aref">ts"_celremovevice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, Lue="">
code=i2c_pmi_basexi2c1/1d/aref">s _pmi_basexi2c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_ue="">
7117-crivers/m/span> code=s _setunister mavice_idc1/1d/aref">i2c_setunister mavice_idc(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devrt"c1/1d/aref">s rt"cr=
code=reorm"c1/1d/aref">reoec-celue="">
731
s _pmicec-oremovec(/spuct code=i2c_clienorm"c1/1d/aref">i2c_clienoec-cr*/span> code=i2crm"c1/1d/aref">i2cec-c,lue="">
code=s _pmic_devd="c1/1d/aref">s _pmic_devec-cr*/span> code=s _pmicd="c1/1d/aref">s _pmicec-celu/span> code=i2crm"_gclienodatad="c1/1d/aref">i2c_setgclienodataec-c(/span> code=i2crm"c1/1d/aref">i2cec-c,m/ue="">
code=s _celremovevice_id"c1/1d/aref">ts"_celremovevice_id"c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devd="c1/1d/aref">devec-c, Lue="">
code=i2c_pmi_basexi2c1/1d/aref">s _pmi_basexi2c(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_ue="">
8118-crivers/m/span> code=s _setunister mavice_idc1/1d/aref">i2c_setunister mavice_idc(/span> code=i2c_pmicd="c1/1d/aref">s _pmicec-c-o_se/span> code=devrt"c1/1d/aref">s rt"cr=
8318/opspe="">
i2c_device_idec-cr*/san> code=s _pmic_dev="c1/1d/aref">i2c_pmic_dev="cr*/= {> 3"s2mppmic_deot;kup" va,> < 0>
> ue="">
code=EXPMODULE_DEVICE_TABLEc1/1d/aref">s5mMODULE_DEVICE_TABLEc(/span> code=i2crm"c1/1d/aref">i2cec-c,m/span> code=s _pmicd="v="c1/1d/aref">i2c_pmic_dev="cr*/ue="">
911 code=reg_devii2c_devi code=s _pmic_devii2c_pmic_devi code=plaii2ci 9319-crivers/mmmmmmmmm./smmmpan> code=plame="c1/1d/aref">i2cme="celu/spa 3"s2mppmic_deot;kup" va,> code=plaownorc1/1d/aref">i2cownorcelu/span> code=i2cTHIS_MODULEc1/1d/aref">i2cTHIS_MODULEc[] code=plabmd="c1/1d/aref"> bmec-c(st/span> code=i2c_pmic_devbmd="c1/1d/aref"> _pmic_probmec-c(st code=plaremovec1/1d/aref">s removec(/s/span> code=i2c_pmic_devremovec1/1d/aref">s _pmicec-oremovec(/s code=plaid_tabldc1/1d/aref">i2c_d_tabldc(/s/span> code=i2c_pmic_dev="c1/1d/aref">i2c_pmic_dev="cr*/>