Lines Matching refs:sel
271 struct dmi_system_event_log sel; \
272 if (sizeof(sel) > dmi_entry_length(dh)) \
274 memcpy(&sel, dh, sizeof(sel)); \
275 return sprintf(buf, "%u\n", sel._field); \
277 static DMI_SYSFS_MAPPED_ATTR(sel, _field)
311 typedef u8 (*sel_io_reader)(const struct dmi_system_event_log *sel,
316 static u8 read_sel_8bit_indexed_io(const struct dmi_system_event_log *sel, in read_sel_8bit_indexed_io() argument
322 outb((u8)offset, sel->io.index_addr); in read_sel_8bit_indexed_io()
323 ret = inb(sel->io.data_addr); in read_sel_8bit_indexed_io()
328 static u8 read_sel_2x8bit_indexed_io(const struct dmi_system_event_log *sel, in read_sel_2x8bit_indexed_io() argument
334 outb((u8)offset, sel->io.index_addr); in read_sel_2x8bit_indexed_io()
335 outb((u8)(offset >> 8), sel->io.index_addr + 1); in read_sel_2x8bit_indexed_io()
336 ret = inb(sel->io.data_addr); in read_sel_2x8bit_indexed_io()
341 static u8 read_sel_16bit_indexed_io(const struct dmi_system_event_log *sel, in read_sel_16bit_indexed_io() argument
347 outw((u16)offset, sel->io.index_addr); in read_sel_16bit_indexed_io()
348 ret = inb(sel->io.data_addr); in read_sel_16bit_indexed_io()
360 const struct dmi_system_event_log *sel, in dmi_sel_raw_read_io() argument
365 sel_io_reader io_reader = sel_io_readers[sel->access_method]; in dmi_sel_raw_read_io()
367 while (count && pos < sel->area_length) { in dmi_sel_raw_read_io()
369 *(buf++) = io_reader(sel, pos++); in dmi_sel_raw_read_io()
377 const struct dmi_system_event_log *sel, in dmi_sel_raw_read_phys32() argument
383 mapped = ioremap(sel->access_method_address, sel->area_length); in dmi_sel_raw_read_phys32()
387 while (count && pos < sel->area_length) { in dmi_sel_raw_read_phys32()
402 struct dmi_system_event_log sel; in dmi_sel_raw_read_helper() local
404 if (sizeof(sel) > dmi_entry_length(dh)) in dmi_sel_raw_read_helper()
407 memcpy(&sel, dh, sizeof(sel)); in dmi_sel_raw_read_helper()
409 switch (sel.access_method) { in dmi_sel_raw_read_helper()
413 return dmi_sel_raw_read_io(entry, &sel, state->buf, in dmi_sel_raw_read_helper()
416 return dmi_sel_raw_read_phys32(entry, &sel, state->buf, in dmi_sel_raw_read_helper()
423 sel.access_method); in dmi_sel_raw_read_helper()