This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Cluster Project".
http://sources.redhat.com/git/gitweb.cgi?p=cluster.git;a=commitdiff;h=63249176ce78b00bd3484d23b28c578270d7fb2b The branch, master has been updated via 63249176ce78b00bd3484d23b28c578270d7fb2b (commit) via 8259c6fe39766e87e4112f8260cc68f3fe3ca93c (commit) via 08b0d3298b67bd8be05c9c854708fe037d70be79 (commit) from 808735b8d2361585fe1292d32ac32671539ee144 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 63249176ce78b00bd3484d23b28c578270d7fb2b Author: Fabio M. Di Nitto <[EMAIL PROTECTED]> Date: Tue May 13 10:51:11 2008 +0200 [GFS] Make gfs build with 2.6.26 (DO NOT USE!) put_inode has been removed from the main kernel. gfs1 needs a full porting and review. This commit allows only to build the module but it will NOT work. Signed-off-by: Fabio M. Di Nitto <[EMAIL PROTECTED]> commit 8259c6fe39766e87e4112f8260cc68f3fe3ca93c Author: Fabio M. Di Nitto <[EMAIL PROTECTED]> Date: Tue May 13 10:27:40 2008 +0200 [GNBD] Update gnbd to work with 2.6.26 Signed-off-by: Fabio M. Di Nitto <[EMAIL PROTECTED]> commit 08b0d3298b67bd8be05c9c854708fe037d70be79 Author: Fabio M. Di Nitto <[EMAIL PROTECTED]> Date: Tue May 13 10:27:12 2008 +0200 [BUILD] Require 2.6.26 kernel to build Signed-off-by: Fabio M. Di Nitto <[EMAIL PROTECTED]> ----------------------------------------------------------------------- Summary of changes: configure | 2 +- gfs-kernel/src/gfs/ops_address.c | 2 +- gfs-kernel/src/gfs/ops_super.c | 6 ++- gfs-kernel/src/gfs/quota.c | 4 +- gnbd-kernel/src/gnbd.c | 91 +++++++++++++++++++------------------- gnbd-kernel/src/gnbd.h | 4 +- 6 files changed, 56 insertions(+), 53 deletions(-) diff --git a/configure b/configure index 60ebe9e..1e6c287 100755 --- a/configure +++ b/configure @@ -28,7 +28,7 @@ my $ret = 0; # this should be only the major version without the extra version # eg. only the first 3 digits -my $required_kernelversion = '2.6.25'; +my $required_kernelversion = '2.6.26'; my %options = ( help => \$help, diff --git a/gfs-kernel/src/gfs/ops_address.c b/gfs-kernel/src/gfs/ops_address.c index 9360ebe..c17d6c4 100644 --- a/gfs-kernel/src/gfs/ops_address.c +++ b/gfs-kernel/src/gfs/ops_address.c @@ -417,7 +417,7 @@ gfs_commit_write(struct file *file, struct page *page, if (inode->i_size < file_size) i_size_write(inode, file_size); } else { - error = generic_commit_write(file, page, from, to); + error = block_commit_write(page, from, to); if (error) goto fail; } diff --git a/gfs-kernel/src/gfs/ops_super.c b/gfs-kernel/src/gfs/ops_super.c index 7f92691..1ee2d93 100644 --- a/gfs-kernel/src/gfs/ops_super.c +++ b/gfs-kernel/src/gfs/ops_super.c @@ -70,6 +70,9 @@ gfs_write_inode(struct inode *inode, int sync) * data. So, sync it out. */ +// XXX FIX ME! + +#if 0 static void gfs_put_inode(struct inode *inode) { @@ -84,6 +87,7 @@ gfs_put_inode(struct inode *inode) !sdp->sd_args.ar_localcaching) gfs_sync_page_i(inode, DIO_START | DIO_WAIT); } +#endif /** * gfs_put_super - Unmount the filesystem @@ -455,7 +459,7 @@ gfs_show_options(struct seq_file *s, struct vfsmount *mnt) struct super_operations gfs_super_ops = { .write_inode = gfs_write_inode, - .put_inode = gfs_put_inode, + // XXX FIX ME .put_inode = gfs_put_inode, .put_super = gfs_put_super, .write_super = gfs_write_super, .write_super_lockfs = gfs_write_super_lockfs, diff --git a/gfs-kernel/src/gfs/quota.c b/gfs-kernel/src/gfs/quota.c index 211b416..9822ab6 100644 --- a/gfs-kernel/src/gfs/quota.c +++ b/gfs-kernel/src/gfs/quota.c @@ -960,8 +960,8 @@ print_quota_message(struct gfs_sbd *sdp, struct gfs_quota_data *qd, char *type) if (current->signal) { tty = current->signal->tty; - if (tty && tty->driver->write) - tty->driver->write(tty, line, len); + if (tty && tty->ops->write) + tty->ops->write(tty, line, len); } kfree(line); diff --git a/gnbd-kernel/src/gnbd.c b/gnbd-kernel/src/gnbd.c index 21ecf9d..f65be50 100644 --- a/gnbd-kernel/src/gnbd.c +++ b/gnbd-kernel/src/gnbd.c @@ -69,26 +69,25 @@ static spinlock_t gnbd_lock = SPIN_LOCK_UNLOCKED; #define to_gnbd_dev(d) container_of(d, struct gnbd_device, class_dev) -static void gnbd_class_release(struct class_device *class_dev) +static void gnbd_class_release(struct device *class_dev) { /* FIXME -- What the hell do I have to free up here */ } static struct class gnbd_class = { .name = "gnbd", - .release = gnbd_class_release + .dev_release = gnbd_class_release }; - -static ssize_t show_pid(struct class_device *class_dev, char *buf) +static ssize_t show_pid(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "%d\n", dev->receiver_pid); } -static CLASS_DEVICE_ATTR(pid, S_IRUGO, show_pid, NULL); +DEVICE_ATTR(pid, S_IRUGO, show_pid, NULL); -static ssize_t show_server(struct class_device *class_dev, char *buf) +static ssize_t show_server(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); if (dev->server_name) @@ -99,7 +98,7 @@ static ssize_t show_server(struct class_device *class_dev, char *buf) } /* FIXME -- should a empty store free the memory */ -static ssize_t store_server(struct class_device *class_dev, +static ssize_t store_server(struct device *class_dev, struct device_attribute *attr, const char *buf, size_t count) { int res; @@ -129,15 +128,15 @@ static ssize_t store_server(struct class_device *class_dev, return count; } -CLASS_DEVICE_ATTR(server, S_IRUGO | S_IWUSR, show_server, store_server); +DEVICE_ATTR(server, S_IRUGO | S_IWUSR, show_server, store_server); -static ssize_t show_name(struct class_device *class_dev, char *buf) +static ssize_t show_name(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "%s\n", dev->name); } -static ssize_t store_name(struct class_device *class_dev, +static ssize_t store_name(struct device *class_dev, struct device_attribute *attr, const char *buf, size_t count) { int res; @@ -151,17 +150,17 @@ static ssize_t store_name(struct class_device *class_dev, return count; } -CLASS_DEVICE_ATTR(name, S_IRUGO | S_IWUSR, show_name, store_name); +DEVICE_ATTR(name, S_IRUGO | S_IWUSR, show_name, store_name); -static ssize_t show_sectors(struct class_device *class_dev, char *buf) +static ssize_t show_sectors(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "%Lu\n", (unsigned long long)get_capacity(dev->disk)); } -static ssize_t store_sectors(struct class_device *class_dev, +static ssize_t store_sectors(struct device *class_dev, struct device_attribute *attr, const char *buf, size_t count) { int res; @@ -190,23 +189,23 @@ static ssize_t store_sectors(struct class_device *class_dev, return count; } -CLASS_DEVICE_ATTR(sectors, S_IRUGO | S_IWUSR, show_sectors, store_sectors); +DEVICE_ATTR(sectors, S_IRUGO | S_IWUSR, show_sectors, store_sectors); -static ssize_t show_usage(struct class_device *class_dev, char *buf) +static ssize_t show_usage(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "%d\n", dev->open_count); } -CLASS_DEVICE_ATTR(usage, S_IRUGO, show_usage, NULL); +DEVICE_ATTR(usage, S_IRUGO, show_usage, NULL); -static ssize_t show_flags(struct class_device *class_dev, char *buf) +static ssize_t show_flags(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "0x%04x\n", dev->flags); } -static ssize_t store_flags(struct class_device *class_dev, +static ssize_t store_flags(struct device *class_dev, struct device_attribute *attr, const char *buf, size_t count) { int res; @@ -222,9 +221,9 @@ static ssize_t store_flags(struct class_device *class_dev, } -CLASS_DEVICE_ATTR(flags, S_IRUGO | S_IWUSR, show_flags, store_flags); +DEVICE_ATTR(flags, S_IRUGO | S_IWUSR, show_flags, store_flags); -static ssize_t show_waittime(struct class_device *class_dev, char *buf) +static ssize_t show_waittime(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); if (list_empty(&dev->queue_head)) @@ -233,15 +232,15 @@ static ssize_t show_waittime(struct class_device *class_dev, char *buf) ((long)jiffies - (long)dev->last_received) / HZ); } -CLASS_DEVICE_ATTR(waittime, S_IRUGO, show_waittime, NULL); +DEVICE_ATTR(waittime, S_IRUGO, show_waittime, NULL); -static ssize_t show_connected(struct class_device *class_dev, char *buf) +static ssize_t show_connected(struct device *class_dev, struct device_attribute *attr, char *buf) { struct gnbd_device *dev = to_gnbd_dev(class_dev); return sprintf(buf, "%d\n", (dev->sock != NULL)); } -CLASS_DEVICE_ATTR(connected, S_IRUGO, show_connected, NULL); +DEVICE_ATTR(connected, S_IRUGO, show_connected, NULL); #ifndef NDEBUG static const char *ioctl_cmd_to_ascii(int cmd) @@ -921,7 +920,7 @@ static int __init gnbd_init(void) gnbd_cmd(&ping_req) = GNBD_CMD_PING; ping_req.sector = 0; ping_req.nr_sectors = 0; - + for (i = 0; i < MAX_GNBD; i++) { struct gendisk *disk = alloc_disk(1); if (!disk) @@ -975,35 +974,35 @@ static int __init gnbd_init(void) init_MUTEX(&gnbd_dev[i].tx_lock); init_MUTEX(&gnbd_dev[i].do_it_lock); gnbd_dev[i].class_dev.class = &gnbd_class; - sprintf(gnbd_dev[i].class_dev.class_id, "gnbd%d", i); - err = class_device_register(&gnbd_dev[i].class_dev); + sprintf(gnbd_dev[i].class_dev.bus_id, "gnbd%d", i); + err = device_register(&gnbd_dev[i].class_dev); if (err){ - printk("class_device_register failed with %d\n", err); + printk("device_register failed with %d\n", err); goto out_unregister_class; } - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_pid)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_pid)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_server)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_server)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_name)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_name)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_sectors)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_sectors)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_usage)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_usage)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_flags)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_flags)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_waittime)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_waittime)) goto out_remove_file; - if(class_device_create_file(&gnbd_dev[i].class_dev, - &class_device_attr_connected)) + if(device_create_file(&gnbd_dev[i].class_dev, + &dev_attr_connected)) goto out_remove_file; disk->major = major_nr; disk->first_minor = i; @@ -1029,11 +1028,11 @@ static int __init gnbd_init(void) out_remove_disk: del_gendisk(gnbd_dev[i].disk); out_remove_file: - class_device_unregister(&gnbd_dev[i].class_dev); + device_unregister(&gnbd_dev[i].class_dev); out_unregister_class: while(i--){ del_gendisk(gnbd_dev[i].disk); - class_device_unregister(&gnbd_dev[i].class_dev); + device_unregister(&gnbd_dev[i].class_dev); } i = MAX_GNBD; class_unregister(&gnbd_class); @@ -1054,7 +1053,7 @@ static void __exit gnbd_cleanup(void) gnbd_ctl_cleanup(); for (i = 0; i < MAX_GNBD; i++) { struct gendisk *disk = gnbd_dev[i].disk; - class_device_unregister(&gnbd_dev[i].class_dev); + device_unregister(&gnbd_dev[i].class_dev); if (disk) { del_gendisk(disk); blk_cleanup_queue(disk->queue); diff --git a/gnbd-kernel/src/gnbd.h b/gnbd-kernel/src/gnbd.h index b88ad26..6de9c08 100644 --- a/gnbd-kernel/src/gnbd.h +++ b/gnbd-kernel/src/gnbd.h @@ -28,7 +28,7 @@ enum { GNBD_CMD_PING = 3 }; -#define gnbd_cmd(req) ((req)->cmd[0]) +#define gnbd_cmd(req) ((req)->__cmd[0]) #define MAX_GNBD 128 /* values for flags field */ @@ -50,7 +50,7 @@ struct gnbd_device { pid_t receiver_pid; struct semaphore do_it_lock; int open_count; - struct class_device class_dev; + struct device class_dev; unsigned short int server_port; char *server_name; char name[32]; hooks/post-receive -- Cluster Project