Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 46437
b: refs/heads/master
c: 1d268b0
h: refs/heads/master
i:
  46435: 00ca946
v: v3
  • Loading branch information
Zhang Rui authored and Len Brown committed Dec 16, 2006
1 parent 1d46f42 commit 69bb8ac
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9e89dde2b063ca73fcdc9244fe68e2dea32c5088
refs/heads/master: 1d268b0a0f5407138caf0dec9559d68e657a3a74
14 changes: 7 additions & 7 deletions trunk/drivers/acpi/scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,21 +49,21 @@ static void setup_sys_fs_device_files(struct acpi_device *dev,
#define remove_sysfs_device_files(dev) \
setup_sys_fs_device_files(dev, (acpi_device_sysfs_files *)&sysfs_remove_file)

#define to_acpi_device(n) container_of(n, struct acpi_device, kobj)
#define to_acpi_dev(n) container_of(n, struct acpi_device, kobj)
#define to_handle_attr(n) container_of(n, struct acpi_device_attribute, attr);

static ssize_t acpi_device_attr_show(struct kobject *kobj,
struct attribute *attr, char *buf)
{
struct acpi_device *device = to_acpi_device(kobj);
struct acpi_device *device = to_acpi_dev(kobj);
struct acpi_device_attribute *attribute = to_handle_attr(attr);
return attribute->show ? attribute->show(device, buf) : -EIO;
}
static ssize_t acpi_device_attr_store(struct kobject *kobj,
struct attribute *attr, const char *buf,
size_t len)
{
struct acpi_device *device = to_acpi_device(kobj);
struct acpi_device *device = to_acpi_dev(kobj);
struct acpi_device_attribute *attribute = to_handle_attr(attr);
return attribute->store ? attribute->store(device, buf, len) : -EIO;
}
Expand All @@ -82,7 +82,7 @@ static int namespace_uevent(struct kset *kset, struct kobject *kobj,
char **envp, int num_envp, char *buffer,
int buffer_size)
{
struct acpi_device *dev = to_acpi_device(kobj);
struct acpi_device *dev = to_acpi_dev(kobj);
int i = 0;
int len = 0;

Expand Down Expand Up @@ -222,7 +222,7 @@ acpi_eject_store(struct acpi_device *device, const char *buf, size_t count)
/* --------------------------------------------------------------------------
ACPI Bus operations
-------------------------------------------------------------------------- */
static inline struct acpi_device * to_acpi_dev(struct device * dev)
static inline struct acpi_device * to_acpi_device(struct device * dev)
{
return container_of(dev, struct acpi_device, dev);
}
Expand Down Expand Up @@ -251,7 +251,7 @@ static int root_suspend(struct acpi_device * acpi_dev, pm_message_t state)

static int acpi_device_suspend(struct device * dev, pm_message_t state)
{
struct acpi_device * acpi_dev = to_acpi_dev(dev);
struct acpi_device * acpi_dev = to_acpi_device(dev);

/*
* For now, we should only register 1 generic device -
Expand Down Expand Up @@ -288,7 +288,7 @@ static int root_resume(struct acpi_device * acpi_dev)

static int acpi_device_resume(struct device * dev)
{
struct acpi_device * acpi_dev = to_acpi_dev(dev);
struct acpi_device * acpi_dev = to_acpi_device(dev);

/*
* For now, we should only register 1 generic device -
Expand Down

0 comments on commit 69bb8ac

Please sign in to comment.