+ revert-gregkh-driver-tty-device.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     revert gregkh-driver-tty-device

has been added to the -mm tree.  Its filename is

     revert-gregkh-driver-tty-device.patch

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: revert gregkh-driver-tty-device
From: Andrew Morton <akpm@xxxxxxxx>

It causes ssh connections to get stuck on an fc3 x86_64 server.

Cc: Greg KH <greg@xxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 drivers/char/tty_io.c            |   19 +++++++++----------
 drivers/isdn/gigaset/common.c    |    2 +-
 drivers/isdn/gigaset/gigaset.h   |    2 +-
 drivers/isdn/gigaset/interface.c |   10 +++++-----
 drivers/isdn/gigaset/proc.c      |   19 +++++++++----------
 include/linux/tty.h              |    5 +++--
 6 files changed, 28 insertions(+), 29 deletions(-)

diff -puN drivers/char/tty_io.c~revert-gregkh-driver-tty-device drivers/char/tty_io.c
--- a/drivers/char/tty_io.c~revert-gregkh-driver-tty-device
+++ a/drivers/char/tty_io.c
@@ -2950,15 +2950,14 @@ static struct class *tty_class;
  *	This field is optional, if there is no known struct device for this
  *	tty device it can be set to NULL safely.
  *
- * Returns a pointer to the struct device for this tty device
- * (or ERR_PTR(-EFOO) on error).
+ * Returns a pointer to the class device (or ERR_PTR(-EFOO) on error).
  *
  * This call is required to be made to register an individual tty device if
  * the tty driver's flags have the TTY_DRIVER_DYNAMIC_DEV bit set.  If that
  * bit is not set, this function should not be called by a tty driver.
  */
-struct device *tty_register_device(struct tty_driver *driver, unsigned index,
-				   struct device *device)
+struct class_device *tty_register_device(struct tty_driver *driver,
+					 unsigned index, struct device *device)
 {
 	char name[64];
 	dev_t dev = MKDEV(driver->major, driver->minor_start) + index;
@@ -2974,7 +2973,7 @@ struct device *tty_register_device(struc
 	else
 		tty_line_name(driver, index, name);
 
-	return device_create(tty_class, device, dev, name);
+	return class_device_create(tty_class, NULL, dev, device, "%s", name);
 }
 
 /**
@@ -2987,7 +2986,7 @@ struct device *tty_register_device(struc
  */
 void tty_unregister_device(struct tty_driver *driver, unsigned index)
 {
-	device_destroy(tty_class, MKDEV(driver->major, driver->minor_start) + index);
+	class_device_destroy(tty_class, MKDEV(driver->major, driver->minor_start) + index);
 }
 
 EXPORT_SYMBOL(tty_register_device);
@@ -3227,20 +3226,20 @@ static int __init tty_init(void)
 	if (cdev_add(&tty_cdev, MKDEV(TTYAUX_MAJOR, 0), 1) ||
 	    register_chrdev_region(MKDEV(TTYAUX_MAJOR, 0), 1, "/dev/tty") < 0)
 		panic("Couldn't register /dev/tty driver\n");
-	device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 0), "tty");
+	class_device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 0), NULL, "tty");
 
 	cdev_init(&console_cdev, &console_fops);
 	if (cdev_add(&console_cdev, MKDEV(TTYAUX_MAJOR, 1), 1) ||
 	    register_chrdev_region(MKDEV(TTYAUX_MAJOR, 1), 1, "/dev/console") < 0)
 		panic("Couldn't register /dev/console driver\n");
-	device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 1), "console");
+	class_device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 1), NULL, "console");
 
 #ifdef CONFIG_UNIX98_PTYS
 	cdev_init(&ptmx_cdev, &ptmx_fops);
 	if (cdev_add(&ptmx_cdev, MKDEV(TTYAUX_MAJOR, 2), 1) ||
 	    register_chrdev_region(MKDEV(TTYAUX_MAJOR, 2), 1, "/dev/ptmx") < 0)
 		panic("Couldn't register /dev/ptmx driver\n");
-	device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 2), "ptmx");
+	class_device_create(tty_class, NULL, MKDEV(TTYAUX_MAJOR, 2), NULL, "ptmx");
 #endif
 
 #ifdef CONFIG_VT
@@ -3248,7 +3247,7 @@ static int __init tty_init(void)
 	if (cdev_add(&vc0_cdev, MKDEV(TTY_MAJOR, 0), 1) ||
 	    register_chrdev_region(MKDEV(TTY_MAJOR, 0), 1, "/dev/vc/0") < 0)
 		panic("Couldn't register /dev/tty0 driver\n");
-	device_create(tty_class, NULL, MKDEV(TTY_MAJOR, 0), "tty0");
+	class_device_create(tty_class, NULL, MKDEV(TTY_MAJOR, 0), NULL, "tty0");
 
 	vty_init();
 #endif
diff -puN drivers/isdn/gigaset/common.c~revert-gregkh-driver-tty-device drivers/isdn/gigaset/common.c
--- a/drivers/isdn/gigaset/common.c~revert-gregkh-driver-tty-device
+++ a/drivers/isdn/gigaset/common.c
@@ -702,7 +702,7 @@ struct cardstate *gigaset_initcs(struct 
 	cs->open_count = 0;
 	cs->dev = NULL;
 	cs->tty = NULL;
-	cs->tty_dev = NULL;
+	cs->class = NULL;
 	cs->cidmode = cidmode != 0;
 
 	//if(onechannel) { //FIXME
diff -puN drivers/isdn/gigaset/gigaset.h~revert-gregkh-driver-tty-device drivers/isdn/gigaset/gigaset.h
--- a/drivers/isdn/gigaset/gigaset.h~revert-gregkh-driver-tty-device
+++ a/drivers/isdn/gigaset/gigaset.h
@@ -444,7 +444,7 @@ struct cardstate {
 	struct gigaset_driver *driver;
 	unsigned minor_index;
 	struct device *dev;
-	struct device *tty_dev;
+	struct class_device *class;
 
 	const struct gigaset_ops *ops;
 
diff -puN drivers/isdn/gigaset/interface.c~revert-gregkh-driver-tty-device drivers/isdn/gigaset/interface.c
--- a/drivers/isdn/gigaset/interface.c~revert-gregkh-driver-tty-device
+++ a/drivers/isdn/gigaset/interface.c
@@ -625,13 +625,13 @@ void gigaset_if_init(struct cardstate *c
 		return;
 
 	tasklet_init(&cs->if_wake_tasklet, &if_wake, (unsigned long) cs);
-	cs->tty_dev = tty_register_device(drv->tty, cs->minor_index, NULL);
+	cs->class = tty_register_device(drv->tty, cs->minor_index, NULL);
 
-	if (!IS_ERR(cs->tty_dev))
-		dev_set_drvdata(cs->tty_dev, cs);
+	if (!IS_ERR(cs->class))
+		class_set_devdata(cs->class, cs);
 	else {
 		warn("could not register device to the tty subsystem");
-		cs->tty_dev = NULL;
+		cs->class = NULL;
 	}
 }
 
@@ -645,7 +645,7 @@ void gigaset_if_free(struct cardstate *c
 
 	tasklet_disable(&cs->if_wake_tasklet);
 	tasklet_kill(&cs->if_wake_tasklet);
-	cs->tty_dev = NULL;
+	cs->class = NULL;
 	tty_unregister_device(drv->tty, cs->minor_index);
 }
 
diff -puN drivers/isdn/gigaset/proc.c~revert-gregkh-driver-tty-device drivers/isdn/gigaset/proc.c
--- a/drivers/isdn/gigaset/proc.c~revert-gregkh-driver-tty-device
+++ a/drivers/isdn/gigaset/proc.c
@@ -16,12 +16,11 @@
 #include "gigaset.h"
 #include <linux/ctype.h>
 
-static ssize_t show_cidmode(struct device *dev,
-			    struct device_attribute *attr, char *buf)
+static ssize_t show_cidmode(struct class_device *class, char *buf)
 {
 	int ret;
 	unsigned long flags;
-	struct cardstate *cs = dev_get_drvdata(dev);
+	struct cardstate *cs = class_get_devdata(class);
 
 	spin_lock_irqsave(&cs->lock, flags);
 	ret = sprintf(buf, "%u\n", cs->cidmode);
@@ -30,10 +29,10 @@ static ssize_t show_cidmode(struct devic
 	return ret;
 }
 
-static ssize_t set_cidmode(struct device *dev, struct device_attribute *attr,
+static ssize_t set_cidmode(struct class_device *class,
 			   const char *buf, size_t count)
 {
-	struct cardstate *cs = dev_get_drvdata(dev);
+	struct cardstate *cs = class_get_devdata(class);
 	long int value;
 	char *end;
 
@@ -65,24 +64,24 @@ static ssize_t set_cidmode(struct device
 	return count;
 }
 
-static DEVICE_ATTR(cidmode, S_IRUGO|S_IWUSR, show_cidmode, set_cidmode);
+static CLASS_DEVICE_ATTR(cidmode, S_IRUGO|S_IWUSR, show_cidmode, set_cidmode);
 
 /* free sysfs for device */
 void gigaset_free_dev_sysfs(struct cardstate *cs)
 {
-	if (!cs->tty_dev)
+	if (!cs->class)
 		return;
 
 	gig_dbg(DEBUG_INIT, "removing sysfs entries");
-	device_remove_file(cs->tty_dev, &dev_attr_cidmode);
+	class_device_remove_file(cs->class, &class_device_attr_cidmode);
 }
 
 /* initialize sysfs for device */
 void gigaset_init_dev_sysfs(struct cardstate *cs)
 {
-	if (!cs->tty_dev)
+	if (!cs->class)
 		return;
 
 	gig_dbg(DEBUG_INIT, "setting up sysfs");
-	device_create_file(cs->tty_dev, &dev_attr_cidmode);
+	class_device_create_file(cs->class, &class_device_attr_cidmode);
 }
diff -puN include/linux/tty.h~revert-gregkh-driver-tty-device include/linux/tty.h
--- a/include/linux/tty.h~revert-gregkh-driver-tty-device
+++ a/include/linux/tty.h
@@ -276,8 +276,9 @@ extern int tty_register_ldisc(int disc, 
 extern int tty_unregister_ldisc(int disc);
 extern int tty_register_driver(struct tty_driver *driver);
 extern int tty_unregister_driver(struct tty_driver *driver);
-extern struct device *tty_register_device(struct tty_driver *driver,
-					  unsigned index, struct device *dev);
+extern struct class_device *tty_register_device(struct tty_driver *driver,
+						unsigned index,
+						struct device *dev);
 extern void tty_unregister_device(struct tty_driver *driver, unsigned index);
 extern int tty_read_raw_data(struct tty_struct *tty, unsigned char *bufp,
 			     int buflen);
_

Patches currently in -mm which might be from akpm@xxxxxxxx are

ext3-avoid-triggering-ext3_error-on-bad-nfs-file-handle-fix.patch
mce-section-fix.patch
disable-debugging-version-of-write_lock.patch
acpi-asus-s3-resume-fix.patch
sony_apci-resume.patch
kauditd_thread-warning-fix.patch
revert-gregkh-driver-class_device_rename-remove.patch
revert-gregkh-driver-network-class_device-to-device.patch
revert-gregkh-driver-tty-device.patch
add-__must_check-to-device-management-code.patch
add-config_enable_must_check.patch
v4l-dev2-handle-__must_check.patch
drivers-base-check-errors.patch
drivers-base-check-errors-fix.patch
sysfs-add-proper-sysfs_init-prototype.patch
scsi-device_reprobe-can-fail.patch
git-dvb.patch
git-dvb-fixup.patch
dvb-core-needs-i2c.patch
git-geode-fixup.patch
git-gfs2.patch
git-ia64.patch
git-ieee1394-fixup.patch
git-input.patch
logips2pp-fix-mx300-button-layout-fix.patch
git-libata-all.patch
sata-is-bust-on-s390.patch
rework-legacy-handling-to-remove-much-of-the-cruft-fix.patch
rework-legacy-handling-to-remove-much-of-the-cruft-powerpc-fix.patch
git-netdev-all.patch
82596-section-fixes.patch
ac3200-section-fixes.patch
cops-section-fix.patch
cs89x0-section-fix.patch
at1700-section-fix.patch
e2100-section-fix.patch
eepro-section-fix.patch
eexpress-section-fix.patch
es3210-section-fix.patch
eth16i-section-fix.patch
lance-section-fix.patch
lne390-section-fix.patch
ni52-section-fix.patch
ibmtr-section-fix.patch
smctr-section-fix.patch
wd-section-fix.patch
ni65-section-fix.patch
seeq8005-section-fix.patch
winbond-840-section-fix.patch
fealnx-section-fix.patch
sundance-section-fix.patch
e1000_7033_dump_ring-fix.patch
s2io-build-fix.patch
drivers-net-ns83820c-add-paramter-to-disable-auto.patch
ppp-handle-kmalloc-failures-leak-fix.patch
xt_physdev-build-fix.patch
git-nfs.patch
git-pcmcia-fixup.patch
git-powerpc-briq_panel-Kconfig-fix.patch
git-sas.patch
serial-fix-uart_bug_txen-test.patch
pcie-check-and-return-bus_register-errors-fix.patch
git-kbuild-build-fix.patch
git-scsi-misc.patch
fix-panic-when-reinserting-adaptec-pcmcia-scsi-card-tidy.patch
areca-sysfs-fix.patch
git-scsi-target-fixup.patch
usb-hub-driver-improve-use-of-ifdef-fix.patch
pm-usb-hcds-use-pm_event_prethaw-fix.patch
kill-usb-kconfig-warning.patch
rtl8150_disconnect-needs-tasklet_kill.patch
git-supertrak-fixup.patch
git-wireless-bcm43xx-fix.patch
kthread-airoc-race-fix.patch
revert-x86_64-mm-ieee1394-early.patch
fix-x86_64-mm-via-force-dma-mask-config_pcin-fix.patch
fix-x86_64-mm-allow-users-to-force-a-panic-on-nmi.patch
sleazy-fpu-feature-x86_64-support.patch
x86_64-wire-up-oops_enter-oops_exit.patch
adix-tree-rcu-lockless-readside-update-tidy.patch
mm-tracking-shared-dirty-pages-checks.patch
mm-tracking-shared-dirty-pages-wimp.patch
convert-i386-numa-kva-space-to-bootmem-tidy.patch
reduce-max_nr_zones-make-display-of-highmem-counters-conditional-on-config_highmem-tidy.patch
reduce-max_nr_zones-use-enum-to-define-zones-reformat-and-comment-cleanup.patch
reduce-max_nr_zones-remove-display-of-counters-for-unconfigured-zones-s390-fix.patch
out-of-memory-notifier-tidy.patch
acx1xx-wireless-driver.patch
tiacx-pci-build-fix.patch
tiacx-ia64-fix.patch
tiacx-build-fix.patch
binfmt_elf-consistently-use-loff_t.patch
synchronize_tsc-fixes.patch
add-force-of-use-mmconfig-fix.patch
convert-i386-summit-subarch-to-use-srat-info-for-apicid_to_node-calls-tidy.patch
add-efi-e820-memory-mapping-on-x86.patch
add-efi-e820-memory-mapping-on-x86-tidy.patch
add-efi-e820-memory-mapping-on-x86-fix.patch
i386-adds-smp_call_function_single-fix.patch
swsusp-write-timer.patch
swsusp-write-speedup.patch
swsusp-read-timer.patch
swsusp-read-speedup.patch
swsusp-read-speedup-fix.patch
swsusp-read-speedup-cleanup.patch
swsusp-read-speedup-cleanup-2.patch
deprecate-smbfs-in-favour-of-cifs.patch
edac-new-opteron-athlon64-memory-controller-driver-tidy.patch
inode_diet-replace-inodeugeneric_ip-with-inodei_private-gfs-fix.patch
x86-microcode-microcode-driver-cleanup-tidy.patch
x86-microcode-add-sysfs-and-hotplug-support-fix.patch
eisa-bus-modalias-attributes-support-1-fix-git-kbuild-fix.patch
add-address_space_operationsbatch_write-fix.patch
alloc_fdtable-cleanup.patch
add-probe_kernel_address.patch
x86-use-probe_kernel_address-in-handle_bug.patch
blockdevc-check-errors.patch
invalidate_bdev-speedup.patch
ide-touch-nmi-watchdog-during-resume-from-str-fix.patch
let-warn_on-warn_on_once-return-the-condition-fix.patch
let-warn_on-warn_on_once-return-the-condition-fix-2.patch
omap-add-watchdog-driver-support-tweaks.patch
reiserfs-on-demand-bitmap-loading.patch
streamline-generic_file_-interfaces-and-filemap-gfs-fix.patch
stack-overflow-safe-kdump-crash_use_safe_smp_processor_id-fix.patch
knfsd-add-a-callback-for-when-last-rpc-thread-finishes-tidy.patch
knfsd-add-a-callback-for-when-last-rpc-thread-finishes-fix.patch
knfsd-separate-out-some-parts-of-nfsd_svc-which-start-nfs-servers-tweaks.patch
knfsd-define-new-nfsdfs-file-portlist-contains-list-of-ports-tidy.patch
knfsd-define-new-nfsdfs-file-portlist-contains-list-of-ports-fix.patch
knfsd-have-ext2-reject-file-handles-with-bad-inode-numbers-early-tidy.patch
knfsd-make-ext3-reject-filehandles-referring-to-invalid-inode-numbers-tidy.patch
knfsd-drop-serv-option-to-svc_recv-and-svc_process-nfs-callback-fix-nfs-callback-fix.patch
swap_prefetch-vs-zoned-counters.patch
ecryptfs-mmap-operations.patch
ecryptfs-alpha-build-fix.patch
ecryptfs-more-elegant-aes-key-size-manipulation.patch
ecryptfs-get_sb_dev-fix.patch
namespaces-add-nsproxy-dont-include-compileh.patch
namespaces-utsname-switch-to-using-uts-namespaces.patch
namespaces-utsname-use-init_utsname-when-appropriate.patch
namespaces-utsname-implement-utsname-namespaces.patch
namespaces-utsname-sysctl-hack.patch
namespaces-utsname-switch-to-using-uts-namespaces-klibc-bit-sparc.patch
ipc-namespace-core.patch
readahead-sysctl-parameters-fix.patch
make-copy_from_user_inatomic-not-zero-the-tail-on-i386-vs-reiser4.patch
reiser4-hardirq-include-fix.patch
reiser4-run-truncate_inode_pages-in-reiser4_delete_inode.patch
reiser4-get_sb_dev-fix.patch
reiser4-vs-zoned-allocator.patch
hpt3xx-rework-rate-filtering-tidy.patch
genirq-convert-the-i386-architecture-to-irq-chips.patch
genirq-x86_64-irq-reenable-migrating-irqs-to-other-cpus.patch
genirq-msi-simplify-msi-enable-and-disable.patch
genirq-ia64-irq-dynamic-irq-support.patch
genirq-msi-only-build-msi-apicc-on-ia64-fix.patch
genirq-i386-irq-remove-the-msi-assumption-that-irq-==-vector.patch
genirq-x86_64-irq-make-vector_irq-per-cpu-fix.patch
add-hypertransport-capability-defines-fix.patch
initial-generic-hypertransport-interrupt-support-Kconfig-fix.patch
nr_blockdev_pages-in_interrupt-warning.patch
device-suspend-debug.patch
revert-tty-buffering-comment-out-debug-code.patch
slab-leaks3-default-y.patch
x86-kmap_atomic-debugging.patch
jmicron-warning-fix.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux