Lines Matching refs:bin
31 struct bin_attribute bin; member
51 if (unlikely(off >= edev->bin.size)) in eeprom_93xx46_bin_read()
53 if ((off + count) > edev->bin.size) in eeprom_93xx46_bin_read()
54 count = edev->bin.size - off; in eeprom_93xx46_bin_read()
203 if (unlikely(off >= edev->bin.size)) in eeprom_93xx46_bin_write()
205 if ((off + count) > edev->bin.size) in eeprom_93xx46_bin_write()
206 count = edev->bin.size - off; in eeprom_93xx46_bin_write()
342 sysfs_bin_attr_init(&edev->bin); in eeprom_93xx46_probe()
343 edev->bin.attr.name = "eeprom"; in eeprom_93xx46_probe()
344 edev->bin.attr.mode = S_IRUSR; in eeprom_93xx46_probe()
345 edev->bin.read = eeprom_93xx46_bin_read; in eeprom_93xx46_probe()
346 edev->bin.size = 128; in eeprom_93xx46_probe()
348 edev->bin.write = eeprom_93xx46_bin_write; in eeprom_93xx46_probe()
349 edev->bin.attr.mode |= S_IWUSR; in eeprom_93xx46_probe()
352 err = sysfs_create_bin_file(&spi->dev.kobj, &edev->bin); in eeprom_93xx46_probe()
379 sysfs_remove_bin_file(&spi->dev.kobj, &edev->bin); in eeprom_93xx46_remove()