diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2008-03-02 09:35:54 -0500 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2008-10-21 07:47:57 -0400 |
commit | b6a895307a6a8d8c294c57d319ec05286d181dac (patch) | |
tree | 3c5404928e67915195a488e9e71f01f019aa5de2 /drivers/block | |
parent | c9acf903e0312dcac3a135c37303adc15e6162a9 (diff) |
[PATCH] switch pd
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/paride/pd.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/block/paride/pd.c b/drivers/block/paride/pd.c index b3023844947c..9299455b0af6 100644 --- a/drivers/block/paride/pd.c +++ b/drivers/block/paride/pd.c | |||
@@ -728,9 +728,9 @@ static int pd_special_command(struct pd_unit *disk, | |||
728 | 728 | ||
729 | /* kernel glue structures */ | 729 | /* kernel glue structures */ |
730 | 730 | ||
731 | static int pd_open(struct inode *inode, struct file *file) | 731 | static int pd_open(struct block_device *bdev, fmode_t mode) |
732 | { | 732 | { |
733 | struct pd_unit *disk = inode->i_bdev->bd_disk->private_data; | 733 | struct pd_unit *disk = bdev->bd_disk->private_data; |
734 | 734 | ||
735 | disk->access++; | 735 | disk->access++; |
736 | 736 | ||
@@ -758,10 +758,10 @@ static int pd_getgeo(struct block_device *bdev, struct hd_geometry *geo) | |||
758 | return 0; | 758 | return 0; |
759 | } | 759 | } |
760 | 760 | ||
761 | static int pd_ioctl(struct inode *inode, struct file *file, | 761 | static int pd_ioctl(struct block_device *bdev, fmode_t mode, |
762 | unsigned int cmd, unsigned long arg) | 762 | unsigned int cmd, unsigned long arg) |
763 | { | 763 | { |
764 | struct pd_unit *disk = inode->i_bdev->bd_disk->private_data; | 764 | struct pd_unit *disk = bdev->bd_disk->private_data; |
765 | 765 | ||
766 | switch (cmd) { | 766 | switch (cmd) { |
767 | case CDROMEJECT: | 767 | case CDROMEJECT: |
@@ -773,9 +773,9 @@ static int pd_ioctl(struct inode *inode, struct file *file, | |||
773 | } | 773 | } |
774 | } | 774 | } |
775 | 775 | ||
776 | static int pd_release(struct inode *inode, struct file *file) | 776 | static int pd_release(struct gendisk *p, fmode_t mode) |
777 | { | 777 | { |
778 | struct pd_unit *disk = inode->i_bdev->bd_disk->private_data; | 778 | struct pd_unit *disk = p->private_data; |
779 | 779 | ||
780 | if (!--disk->access && disk->removable) | 780 | if (!--disk->access && disk->removable) |
781 | pd_special_command(disk, pd_door_unlock); | 781 | pd_special_command(disk, pd_door_unlock); |
@@ -807,9 +807,9 @@ static int pd_revalidate(struct gendisk *p) | |||
807 | 807 | ||
808 | static struct block_device_operations pd_fops = { | 808 | static struct block_device_operations pd_fops = { |
809 | .owner = THIS_MODULE, | 809 | .owner = THIS_MODULE, |
810 | .__open = pd_open, | 810 | .open = pd_open, |
811 | .__release = pd_release, | 811 | .release = pd_release, |
812 | .__ioctl = pd_ioctl, | 812 | .locked_ioctl = pd_ioctl, |
813 | .getgeo = pd_getgeo, | 813 | .getgeo = pd_getgeo, |
814 | .media_changed = pd_check_media, | 814 | .media_changed = pd_check_media, |
815 | .revalidate_disk= pd_revalidate | 815 | .revalidate_disk= pd_revalidate |