Lines Matching +full:manufacturer +full:- +full:id
1 // SPDX-License-Identifier: GPL-2.0
3 #include <linux/mtd/spi-nor.h>
5 #include <linux/spi/spi-mem.h>
17 return sysfs_emit(buf, "%s\n", nor->manufacturer->name); in manufacturer_show()
19 static DEVICE_ATTR_RO(manufacturer);
28 return sysfs_emit(buf, "%s\n", nor->info->name); in partname_show()
38 const u8 *id = nor->info->id ? nor->info->id->bytes : nor->id; in jedec_id_show() local
39 u8 id_len = nor->info->id ? nor->info->id->len : SPI_NOR_MAX_ID_LEN; in jedec_id_show()
41 return sysfs_emit(buf, "%*phN\n", id_len, id); in jedec_id_show()
59 struct sfdp *sfdp = nor->sfdp; in sfdp_read()
60 size_t sfdp_size = sfdp->num_dwords * sizeof(*sfdp->dwords); in sfdp_read()
62 return memory_read_from_buffer(buf, count, &off, nor->sfdp->dwords, in sfdp_read()
79 if (attr == &dev_attr_manufacturer.attr && !nor->manufacturer) in spi_nor_sysfs_is_visible()
81 if (attr == &dev_attr_partname.attr && !nor->info->name) in spi_nor_sysfs_is_visible()
83 if (attr == &dev_attr_jedec_id.attr && !nor->info->id && !nor->id) in spi_nor_sysfs_is_visible()
96 if (attr == &bin_attr_sfdp && nor->sfdp) in spi_nor_sysfs_is_bin_visible()
103 .name = "spi-nor",