Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
98c23bfa
Commit
98c23bfa
authored
Jun 03, 2003
by
Patrick Mochel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[driver model] Update copyrights and license statements.
It's a slow afternoon.
parent
e3dc27ee
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
62 additions
and
30 deletions
+62
-30
drivers/base/bus.c
drivers/base/bus.c
+5
-4
drivers/base/class.c
drivers/base/class.c
+5
-1
drivers/base/core.c
drivers/base/core.c
+5
-2
drivers/base/driver.c
drivers/base/driver.c
+5
-0
drivers/base/firmware.c
drivers/base/firmware.c
+6
-0
drivers/base/init.c
drivers/base/init.c
+8
-0
drivers/base/interface.c
drivers/base/interface.c
+6
-2
drivers/base/platform.c
drivers/base/platform.c
+5
-0
drivers/base/power.c
drivers/base/power.c
+9
-5
drivers/base/sys.c
drivers/base/sys.c
+4
-2
include/linux/device.h
include/linux/device.h
+4
-14
No files found.
drivers/base/bus.c
View file @
98c23bfa
/*
* bus.c - bus driver management
*
* Copyright (c) 2002 Patrick Mochel
*
2002 Open Source Development Lab
* Copyright (c) 2002
-3
Patrick Mochel
*
Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
...
...
drivers/base/class.c
View file @
98c23bfa
/*
* class.c - basic device class management
*
* Copyright (c) 2001-2003 Patrick Mochel <mochel@osdl.org>
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#undef DEBUG
...
...
drivers/base/core.c
View file @
98c23bfa
/*
* drivers/base/core.c - core driver model code (device registration, etc)
*
* Copyright (c) 2002 Patrick Mochel
* 2002 Open Source Development Lab
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#undef DEBUG
...
...
drivers/base/driver.c
View file @
98c23bfa
/*
* driver.c - centralized device driver management
*
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#undef DEBUG
...
...
drivers/base/firmware.c
View file @
98c23bfa
/*
* firmware.c - firmware subsystem hoohaw.
*
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#include <linux/kobject.h>
...
...
drivers/base/init.c
View file @
98c23bfa
/*
*
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#include <linux/device.h>
#include <linux/init.h>
...
...
drivers/base/interface.c
View file @
98c23bfa
/*
* drivers/base/interface.c - common driverfs interface that's exported to
* the world for all devices.
* Copyright (c) 2002 Patrick Mochel
* 2002 Open Source Development Lab
*
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
*/
#include <linux/device.h>
...
...
drivers/base/platform.c
View file @
98c23bfa
/*
* platform.c - platform 'psuedo' bus for legacy devices
*
* Copyright (c) 2002-3 Patrick Mochel
* Copyright (c) 2002-3 Open Source Development Labs
*
* This file is released under the GPLv2
*
* Please see Documentation/driver-model/platform.txt for more
* information.
*/
...
...
drivers/base/power.c
View file @
98c23bfa
/*
* power.c - power management functions for the device tree.
*
* Copyright (c) 2002 Patrick Mochel
* 2002 Open Source Development Lab
* Copyright (c) 2002-3 Patrick Mochel
* 2002-3 Open Source Development Lab
*
* This file is released under the GPLv2
*
* Kai Germaschewski contributed to the list walking routines.
*
*/
#
undef
DEBUG
#
define
DEBUG
#include <linux/device.h>
#include <linux/module.h>
...
...
@@ -88,10 +90,12 @@ void device_shutdown(void)
down_write
(
&
devices_subsys
.
rwsem
);
list_for_each
(
entry
,
&
devices_subsys
.
kset
.
list
)
{
struct
device
*
dev
=
to_dev
(
entry
);
pr_debug
(
"shutting down %s: "
,
dev
->
name
);
if
(
dev
->
driver
&&
dev
->
driver
->
shutdown
)
{
pr_debug
(
"
shutting down %s
\n
"
,
dev
->
name
);
pr_debug
(
"
Ok
\n
"
);
dev
->
driver
->
shutdown
(
dev
);
}
}
else
pr_debug
(
"Ignored.
\n
"
);
}
up_write
(
&
devices_subsys
.
rwsem
);
}
...
...
drivers/base/sys.c
View file @
98c23bfa
/*
* sys.c - pseudo-bus for system 'devices' (cpus, PICs, timers, etc)
*
* Copyright (c) 2002 Patrick Mochel
* 2002 Open Source Development Lab
* Copyright (c) 2002-3 Patrick Mochel
* 2002-3 Open Source Development Lab
*
* This file is released under the GPLv2
*
* This exports a 'system' bus type.
* By default, a 'sys' bus gets added to the root of the system. There will
...
...
include/linux/device.h
View file @
98c23bfa
...
...
@@ -3,21 +3,9 @@
*
* Copyright (c) 2001-2003 Patrick Mochel <mochel@osdl.org>
*
* This is a relatively simple centralized driver model.
* The data structures were mainly lifted directly from the PCI
* driver model. These are thought to be the common fields that
* are relevant to all device buses.
* This file is released under the GPLv2
*
* All the devices are arranged in a tree. All devices should
* have some sort of parent bus of whom they are children of.
* Devices should not be direct children of the system root.
*
* Device drivers should not directly call the device_* routines
* or access the contents of struct device directly. Instead,
* abstract that from the drivers and write bus-specific wrappers
* that do it for you.
*
* See Documentation/driver-model.txt for more information.
* See Documentation/driver-model/*.txt for more information.
*/
#ifndef _DEVICE_H_
...
...
@@ -169,6 +157,8 @@ struct class {
int
(
*
hotplug
)(
struct
class_device
*
dev
,
char
**
envp
,
int
num_envp
,
char
*
buffer
,
int
buffer_size
);
void
(
*
release
)(
struct
class_device
*
dev
);
};
extern
int
class_register
(
struct
class
*
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment