Lines Matching refs:nvmem_cfg
127 struct nvmem_config *nvmem_cfg; in sunxi_sid_probe() local
149 nvmem_cfg = devm_kzalloc(dev, sizeof(*nvmem_cfg), GFP_KERNEL); in sunxi_sid_probe()
150 if (!nvmem_cfg) in sunxi_sid_probe()
153 nvmem_cfg->dev = dev; in sunxi_sid_probe()
154 nvmem_cfg->name = "sunxi-sid"; in sunxi_sid_probe()
155 nvmem_cfg->type = NVMEM_TYPE_OTP; in sunxi_sid_probe()
156 nvmem_cfg->add_legacy_fixed_of_cells = true; in sunxi_sid_probe()
157 nvmem_cfg->read_only = true; in sunxi_sid_probe()
158 nvmem_cfg->size = cfg->size; in sunxi_sid_probe()
159 nvmem_cfg->word_size = 1; in sunxi_sid_probe()
160 nvmem_cfg->stride = 4; in sunxi_sid_probe()
161 nvmem_cfg->priv = sid; in sunxi_sid_probe()
163 nvmem_cfg->reg_read = sun8i_sid_read_by_reg; in sunxi_sid_probe()
165 nvmem_cfg->reg_read = sunxi_sid_read; in sunxi_sid_probe()
167 nvmem = devm_nvmem_register(dev, nvmem_cfg); in sunxi_sid_probe()
175 nvmem_cfg->reg_read(sid, 0, randomness, size); in sunxi_sid_probe()