projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
pci-quirks: disable MSI on RS400-200 and RS480
[powerpc.git]
/
drivers
/
macintosh
/
apm_emu.c
diff --git
a/drivers/macintosh/apm_emu.c
b/drivers/macintosh/apm_emu.c
index
8862a83
..
cdb0bea
100644
(file)
--- a/
drivers/macintosh/apm_emu.c
+++ b/
drivers/macintosh/apm_emu.c
@@
-96,13
+96,13
@@
static DECLARE_WAIT_QUEUE_HEAD(apm_waitqueue);
static DECLARE_WAIT_QUEUE_HEAD(apm_suspend_waitqueue);
static struct apm_user * user_list;
static DECLARE_WAIT_QUEUE_HEAD(apm_suspend_waitqueue);
static struct apm_user * user_list;
-static
int
apm_notify_sleep(struct pmu_sleep_notifier *self, int when);
+static
void
apm_notify_sleep(struct pmu_sleep_notifier *self, int when);
static struct pmu_sleep_notifier apm_sleep_notifier = {
apm_notify_sleep,
SLEEP_LEVEL_USERLAND,
};
static struct pmu_sleep_notifier apm_sleep_notifier = {
apm_notify_sleep,
SLEEP_LEVEL_USERLAND,
};
-static c
har driver_version[] = "0.5";
/* no spaces */
+static c
onst char driver_version[] = "0.5";
/* no spaces */
#ifdef DEBUG
static char * apm_event_name[] = {
#ifdef DEBUG
static char * apm_event_name[] = {
@@
-321,7
+321,7
@@
static int do_open(struct inode * inode, struct file * filp)
{
struct apm_user * as;
{
struct apm_user * as;
- as =
(struct apm_user *)
kmalloc(sizeof(*as), GFP_KERNEL);
+ as = kmalloc(sizeof(*as), GFP_KERNEL);
if (as == NULL) {
printk(KERN_ERR "apm: cannot allocate struct of size %d bytes\n",
sizeof(*as));
if (as == NULL) {
printk(KERN_ERR "apm: cannot allocate struct of size %d bytes\n",
sizeof(*as));
@@
-352,7
+352,7
@@
static int do_open(struct inode * inode, struct file * filp)
* doesn't provide a way to NAK, but this could be added
* here.
*/
* doesn't provide a way to NAK, but this could be added
* here.
*/
-static
int
wait_all_suspend(void)
+static
void
wait_all_suspend(void)
{
DECLARE_WAITQUEUE(wait, current);
{
DECLARE_WAITQUEUE(wait, current);
@@
-366,24
+366,19
@@
static int wait_all_suspend(void)
remove_wait_queue(&apm_suspend_waitqueue, &wait);
DBG("apm_emu: wait_all_suspend() - complete !\n");
remove_wait_queue(&apm_suspend_waitqueue, &wait);
DBG("apm_emu: wait_all_suspend() - complete !\n");
-
- return 1;
}
}
-static
int
apm_notify_sleep(struct pmu_sleep_notifier *self, int when)
+static
void
apm_notify_sleep(struct pmu_sleep_notifier *self, int when)
{
switch(when) {
case PBOOK_SLEEP_REQUEST:
queue_event(APM_SYS_SUSPEND, NULL);
{
switch(when) {
case PBOOK_SLEEP_REQUEST:
queue_event(APM_SYS_SUSPEND, NULL);
- if (!wait_all_suspend())
- return PBOOK_SLEEP_REFUSE;
+ wait_all_suspend();
break;
break;
- case PBOOK_SLEEP_REJECT:
case PBOOK_WAKE:
queue_event(APM_NORMAL_RESUME, NULL);
break;
}
case PBOOK_WAKE:
queue_event(APM_NORMAL_RESUME, NULL);
break;
}
- return PBOOK_SLEEP_OK;
}
#define APM_CRITICAL 10
}
#define APM_CRITICAL 10
@@
-501,7
+496,7
@@
static int apm_emu_get_info(char *buf, char **start, off_t fpos, int length)
return p - buf;
}
return p - buf;
}
-static struct file_operations apm_bios_fops = {
+static
const
struct file_operations apm_bios_fops = {
.owner = THIS_MODULE,
.read = do_read,
.poll = do_poll,
.owner = THIS_MODULE,
.read = do_read,
.poll = do_poll,