Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 17899
b: refs/heads/master
c: 4ab2495
h: refs/heads/master
i:
  17897: 4158249
  17895: bb13fcb
v: v3
  • Loading branch information
Alan Cox authored and Linus Torvalds committed Jan 12, 2006
1 parent 1849120 commit b5133c1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 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: b7599587faea9403edf4d7f74e80b3c9ea217930
refs/heads/master: 4ab2495a30bb3de1cfe41a886f83afb68616ab7d
15 changes: 7 additions & 8 deletions trunk/drivers/char/tlclk.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ static int tlclk_open(struct inode *inode, struct file *filp)
result = request_irq(telclk_interrupt, &tlclk_interrupt,
SA_INTERRUPT, "telco_clock", tlclk_interrupt);
if (result == -EBUSY) {
printk(KERN_ERR "telco_clock: Interrupt can't be reserved!\n");
printk(KERN_ERR "tlclk: Interrupt can't be reserved.\n");
return -EBUSY;
}
inb(TLCLK_REG6); /* Clear interrupt events */
Expand Down Expand Up @@ -741,7 +741,7 @@ static int __init tlclk_init(void)

ret = register_chrdev(tlclk_major, "telco_clock", &tlclk_fops);
if (ret < 0) {
printk(KERN_ERR "telco_clock: can't get major! %d\n", tlclk_major);
printk(KERN_ERR "tlclk: can't get major %d.\n", tlclk_major);
return ret;
}
alarm_events = kzalloc( sizeof(struct tlclk_alarms), GFP_KERNEL);
Expand All @@ -750,15 +750,15 @@ static int __init tlclk_init(void)

/* Read telecom clock IRQ number (Set by BIOS) */
if (!request_region(TLCLK_BASE, 8, "telco_clock")) {
printk(KERN_ERR "tlclk: request_region failed! 0x%X\n",
printk(KERN_ERR "tlclk: request_region 0x%X failed.\n",
TLCLK_BASE);
ret = -EBUSY;
goto out2;
}
telclk_interrupt = (inb(TLCLK_REG7) & 0x0f);

if (0x0F == telclk_interrupt ) { /* not MCPBL0010 ? */
printk(KERN_ERR "telclk_interrup = 0x%x non-mcpbl0010 hw\n",
printk(KERN_ERR "telclk_interrup = 0x%x non-mcpbl0010 hw.\n",
telclk_interrupt);
ret = -ENXIO;
goto out3;
Expand All @@ -768,24 +768,23 @@ static int __init tlclk_init(void)

ret = misc_register(&tlclk_miscdev);
if (ret < 0) {
printk(KERN_ERR " misc_register retruns %d\n", ret);
printk(KERN_ERR "tlclk: misc_register returns %d.\n", ret);
ret = -EBUSY;
goto out3;
}

tlclk_device = platform_device_register_simple("telco_clock",
-1, NULL, 0);
if (!tlclk_device) {
printk(KERN_ERR " platform_device_register retruns 0x%X\n",
(unsigned int) tlclk_device);
printk(KERN_ERR "tlclk: platform_device_register failed.\n");
ret = -EBUSY;
goto out4;
}

ret = sysfs_create_group(&tlclk_device->dev.kobj,
&tlclk_attribute_group);
if (ret) {
printk(KERN_ERR "failed to create sysfs device attributes\n");
printk(KERN_ERR "tlclk: failed to create sysfs device attributes.\n");
sysfs_remove_group(&tlclk_device->dev.kobj,
&tlclk_attribute_group);
goto out5;
Expand Down

0 comments on commit b5133c1

Please sign in to comment.