Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 82628
b: refs/heads/master
c: 44414e1
h: refs/heads/master
v: v3
  • Loading branch information
Stephen Rothwell authored and Greg Kroah-Hartman committed Feb 2, 2008
1 parent 913fdcd commit 54e9cd5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 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: cd35449b93ac128282c1f1f720e84c5935f9018e
refs/heads/master: 44414e14af3f18fc8c1b94e259cd760366f665ee
6 changes: 3 additions & 3 deletions trunk/Documentation/driver-model/platform.txt
Original file line number Diff line number Diff line change
Expand Up @@ -122,15 +122,15 @@ None the less, there are some APIs to support such legacy drivers. Avoid
using these calls except with such hotplug-deficient drivers.

struct platform_device *platform_device_alloc(
char *name, unsigned id);
const char *name, int id);

You can use platform_device_alloc() to dynamically allocate a device, which
you will then initialize with resources and platform_device_register().
A better solution is usually:

struct platform_device *platform_device_register_simple(
char *name, unsigned id,
struct resource *res, unsigned nres);
const char *name, int id,
struct resource *res, unsigned int nres);

You can use platform_device_register_simple() as a one-step call to allocate
and register a device.
Expand Down

0 comments on commit 54e9cd5

Please sign in to comment.