Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
zorro-sysfs.c File Reference
#include <linux/kernel.h>
#include <linux/zorro.h>
#include <linux/stat.h>
#include <linux/string.h>
#include "zorro.h"

Go to the source code of this file.

Macros

#define zorro_config_attr(name, field, format_string)
 

Functions

 zorro_config_attr (id, id,"0x%08x\n")
 
 zorro_config_attr (type, rom.er_Type,"0x%02x\n")
 
 zorro_config_attr (serial, rom.er_SerialNumber,"0x%08x\n")
 
 zorro_config_attr (slotaddr, slotaddr,"0x%04x\n")
 
 zorro_config_attr (slotsize, slotsize,"0x%04x\n")
 
int zorro_create_sysfs_dev_files (struct zorro_dev *z)
 

Macro Definition Documentation

#define zorro_config_attr (   name,
  field,
  format_string 
)
Value:
static ssize_t \
show_##name(struct device *dev, struct device_attribute *attr, char *buf) \
{ \
struct zorro_dev *z; \
\
z = to_zorro_dev(dev); \
return sprintf(buf, format_string, z->field); \
} \
static DEVICE_ATTR(name, S_IRUGO, show_##name, NULL);

Definition at line 23 of file zorro-sysfs.c.

Function Documentation

zorro_config_attr ( id  ,
id  ,
"0x%08x\n"   
)
zorro_config_attr ( type  ,
rom.  er_Type,
"0x%02x\n"   
)
zorro_config_attr ( serial  ,
rom.  er_SerialNumber,
"0x%08x\n"   
)
zorro_config_attr ( slotaddr  ,
slotaddr  ,
"0x%04x\n"   
)
zorro_config_attr ( slotsize  ,
slotsize  ,
"0x%04x\n"   
)
int zorro_create_sysfs_dev_files ( struct zorro_dev *  z)

Definition at line 90 of file zorro-sysfs.c.