This is a note to let you know that I've just added the patch titled Subject: USB: serial: option: clean up urb->status usage
to my gregkh-2.6 tree. Its filename is usb-option-status.patch This tree can be found at http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/patches/ >From [EMAIL PROTECTED] Tue Apr 9 12:12:43 2002 Date: Fri, 15 Jun 2007 15:44:13 -0700 To: Greg KH <[EMAIL PROTECTED]> From: Greg Kroah-Hartman <[EMAIL PROTECTED]> Subject: USB: serial: option: clean up urb->status usage From: Greg Kroah-Hartman <[EMAIL PROTECTED]> This done in anticipation of removal of urb->status, which will make that patch easier to review and apply in the future. Cc: <linux-usb-devel@lists.sourceforge.net> Cc: Matthias Urlichs <[EMAIL PROTECTED]> Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]> --- drivers/usb/serial/option.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) --- a/drivers/usb/serial/option.c +++ b/drivers/usb/serial/option.c @@ -414,15 +414,16 @@ static void option_indat_callback(struct struct usb_serial_port *port; struct tty_struct *tty; unsigned char *data = urb->transfer_buffer; + int status = urb->status; dbg("%s: %p", __FUNCTION__, urb); endpoint = usb_pipeendpoint(urb->pipe); port = (struct usb_serial_port *) urb->context; - if (urb->status) { + if (status) { dbg("%s: nonzero status: %d on endpoint %02x.", - __FUNCTION__, urb->status, endpoint); + __FUNCTION__, status, endpoint); } else { tty = port->tty; if (urb->actual_length) { @@ -434,7 +435,7 @@ static void option_indat_callback(struct } /* Resubmit urb so we continue receiving */ - if (port->open_count && urb->status != -ESHUTDOWN) { + if (port->open_count && status != -ESHUTDOWN) { err = usb_submit_urb(urb, GFP_ATOMIC); if (err) printk(KERN_ERR "%s: resubmit read urb failed. " @@ -469,6 +470,7 @@ static void option_outdat_callback(struc static void option_instat_callback(struct urb *urb) { int err; + int status = urb->status; struct usb_serial_port *port = (struct usb_serial_port *) urb->context; struct option_port_private *portdata = usb_get_serial_port_data(port); struct usb_serial *serial = port->serial; @@ -476,7 +478,7 @@ static void option_instat_callback(struc dbg("%s", __FUNCTION__); dbg("%s: urb %p port %p has data %p", __FUNCTION__,urb,port,portdata); - if (urb->status == 0) { + if (status == 0) { struct usb_ctrlrequest *req_pkt = (struct usb_ctrlrequest *)urb->transfer_buffer; @@ -507,10 +509,10 @@ static void option_instat_callback(struc req_pkt->bRequestType,req_pkt->bRequest); } } else - dbg("%s: error %d", __FUNCTION__, urb->status); + dbg("%s: error %d", __FUNCTION__, status); /* Resubmit urb so we continue receiving IRQ data */ - if (urb->status != -ESHUTDOWN) { + if (status != -ESHUTDOWN) { urb->dev = serial->dev; err = usb_submit_urb(urb, GFP_ATOMIC); if (err) Patches currently in gregkh-2.6 which might be from [EMAIL PROTECTED] are bad/pci-domain/pci-device-ensure-sysdata-initialised.patch bad/pci-domain/pci-fix-the-x86-pci-domain-support-fix.patch bad/relayfs/sysfs-update-relay-file-support-for-generic-relay-api.patch bad/relayfs/relay-consolidate-relayfs-core-into-kernel-relay.c.patch bad/relayfs/relay-relay-header-cleanup.patch bad/relayfs/relayfs-remove-relayfs-in-favour-of-config_relay.patch bad/relayfs/sysfs-add-__attr_relay-helper-for-relay-attributes.patch bad/relayfs/sysfs-relay-channel-buffers-as-sysfs-attributes.patch bad/usbip/usb-usbip-more-dead-code-fix.patch bad/usbip/usb-usbip-build-fix.patch bad/usbip/usb-usbip-warning-fixes.patch bad/ndevfs.patch bad/battery-class-driver.patch bad/driver-model-convert-driver-model-to-mutexes.patch bad/gpl_future-test.patch bad/gregkh-debugfs_example.patch bad/speakup-kconfig-fix.patch bad/speakup-build-fix.patch bad/pci-use-new-multi-phase-suspend-infrastructure.patch bad/shot-accross-the-bow.patch bad/no-more-non-gpl-modules.patch bad/spi-device.patch bad/ata_piix-multithread.patch bad/uio-irq.patch bad/pci-two-drivers-on-one-pci-device.patch bad/pci-dynamic-id-cleanup.patch bad/input-device.patch driver/nozomi.patch driver/uio.patch driver/uio-documentation.patch driver/driver-core-make-devt_attr-and-uevent_attr-static.patch driver/sysfs-rules.patch driver/uio-hilscher-cif-card-driver.patch driver/sysfs-add-sysfs_dirent-s_name.patch driver/debugfs-add-rename-for-debugfs-files.patch driver/sysfs-consolidate-sysfs_dirent-creation-functions.patch driver/sysfs-add-sysfs_dirent-s_parent.patch driver/sysfs-allocate-inode-number-using-ida.patch driver/sysfs-kill-attribute-file-orphaning.patch driver/sysfs-fix-error-handling-in-binattr-write.patch driver/sysfs-flatten-and-fix-sysfs_rename_dir-error-handling.patch driver/sysfs-flatten-cleanup-paths-in-sysfs_add_link-and-create_dir.patch driver/sysfs-implement-bin_buffer.patch driver/sysfs-implement-kobj_sysfs_assoc_lock.patch driver/sysfs-implement-sysfs_dirent-active-reference-and-immediate-disconnect.patch driver/sysfs-kill-unnecessary-attribute-owner.patch driver/sysfs-make-sysfs_dirent-s_element-a-union.patch driver/howto-translated-into-japanese.patch driver/sysfs-make-sysfs_put-ignore-null-sd.patch driver/sysfs-move-release_sysfs_dirent-to-dir.c.patch driver/sysfs-reimplement-symlink-using-sysfs_dirent-tree.patch driver/sysfs-reimplement-sysfs_drop_dentry.patch driver/sysfs-separate-out-sysfs_attach_dentry.patch driver/ida-implement-idr-based-id-allocator.patch driver/idr-fix-obscure-bug-in-allocation-path.patch driver/idr-separate-out-idr_mark_full.patch driver/sysfs-fix-oops-in-sysfs_drop_dentry-on-x86_64.patch driver/sysfs-fix-root-sysfs_dirent-root-dentry-association.patch driver/driver-core-add-missing-kset-uevent.patch driver/power-management-use-mutexes-instead-of-semaphores.patch driver/sysdev-use-mutex-instead-of-semaphore.patch driver/sysfs-fix-parent-refcounting-during-rename-and-move.patch driver/sysfs-implement-sysfs_find_dirent-and-sysfs_get_dirent.patch driver/sysfs-make-sysfs_alloc_ino-static.patch driver/sysfs-move-s_active-functions-to-fs-sysfs-dir.c.patch driver/sysfs-reorganize-sysfs_new_indoe-and-sysfs_create.patch driver/sysfs-slim-down-sysfs_dirent-s_active.patch driver/sysfs-use-iget_locked-instead-of-new_inode.patch driver/sysfs-use-singly-linked-list-for-sysfs_dirent-tree.patch driver/sysfs-use-sysfs_mutex-to-protect-the-sysfs_dirent-tree.patch driver/pm-remove-pm_parent-from-struct-dev_pm_info.patch driver/pm-remove-saved_state-from-struct-dev_pm_info.patch driver/pm-simplify-suspend_device.patch driver/sysfs-consolidate-sysfs-spinlocks.patch driver/sysfs-implement-sysfs_flag_removed-flag.patch driver/sysfs-implement-sysfs_get_dentry.patch driver/sysfs-make-directory-dentries-and-inodes-reclaimable.patch driver/sysfs-make-kobj-point-to-sysfs_dirent-instead-of-dentry.patch driver/sysfs-make-sysfs_drop_dentry-access-inodes-using-ilookup.patch driver/sysfs-move-sysfs_drop_dentry-to-dir.c-and-make-it-static.patch driver/sysfs-rename-sysfs_dirent-s_type-to-s_flags-and-make-room-for-flags.patch driver/sysfs-restructure-add-remove-paths-and-fix-inode-update.patch gregkh/gkh-version.patch gregkh/sysfs-test.patch gregkh/sysrq-u-laptop.patch pci/pci_bridge-device.patch pci/pci-piggy-bus.patch pci/pci-make-pcibios_add_platform_entries-return-errors.patch pci/pci-use-a-weak-symbol-for-the-empty-version-of-pcibios_add_platform_entries.patch pci/pci-pci_find_slot-mark-deprecated.patch pci/pci-remove-cpqphp-maintainer.patch pci/pci-remove-useless-pci-driver-method.patch pci/pci-fix-the-error-message-to-point-to-the-proper-person.patch pci/pci-syscall.c-switch-to-refcounting-api.patch usb/usb-gotemp.patch usb/usb-stimulus.patch usb/usb-add-usb-persist-facility.patch usb/usb-core-hub.c-prevent-re-enumeration-on-hnp.patch usb/usb-serial-license-fix.patch usb/usb-aircable-status.patch usb/usb-airprime-status.patch usb/usb-belkin_sa-status.patch usb/usb-ehci-safe-endianness-for-transfer-buffers-after-reset-in-case-of-hub-with-tt.patch usb/usb-cyberjack-status.patch usb/usb-cypress_m8-status.patch usb/usb-digi_acceleport-status.patch usb/usb-empeg-status.patch usb/usb-ftdi_sio-status.patch usb/usb-usb-serial-gadget-sparse-fixes.patch usb/usb-suspend-support-for-usb-serial.patch usb/usb-add-reset_resume-device-quirk.patch usb/usb-ehci-cpufreq-fix.patch usb/usb-ehci-support-for-big-endian-descriptors.patch usb/usb-garmin_gps-status.patch usb/usb-don-t-unsuspend-for-a-new-connection.patch usb/usb-implement-pm-freeze-and-prethaw.patch usb/usb-disable-file_storage-usb_config_att_wakeup.patch usb/usb-interface-pm-state.patch usb/usb-make-hub-driver-s-release-more-robust.patch usb/usb-move-bus_suspend-and-bus_resume-method-calls.patch usb/usb-remove-locktree-routine-from-the-hub-driver.patch usb/usb-remove-references-to-dev.power.power_state.patch usb/usb-generic-status.patch usb/usb-io_edgeport-status.patch usb/usb-io_ti-status.patch usb/usb-cxacru-cleanup-sysfs-attribute-code.patch usb/usb-make-device-reset-stop-retrying-after-disconnect.patch usb/usb-add-power-persist-device-attribute.patch usb/usb-ipw-status.patch usb/usb-ehci-refcounts-work-on-ppc7448.patch usb/usb-m66592-udc-peripheral-controller-driver-for-m66592.patch usb/usb-add-reset_resume-method.patch usb/usb-r8a66597-hcd-host-controller-driver-for-r8a66597.patch usb/usb-g_file_storage-call-allow_signal.patch usb/usb-m66592-udc-fix-use-old-interrupt-flags.patch usb/usb-ipaq-status.patch usb/usb-serial-keyspan-add-support-for-usa-49wg-usa-28xg.patch usb/usb-use-menuconfig-objects.patch usb/usb-r8a66597-hcd-fix-null-access.patch usb/usb-remove-__usb_port_suspend.patch usb/usb-remove-excess-code-from-hub.c.patch usb/usb-separate-root-and-non-root-suspend-resume.patch usb/usb-unify-reset_resume-and-normal-resume.patch usb/usb-fsl_usb2_udc-get-max-ep-number-from-dccparams-register.patch usb/usb-add-usb_device_and_interface_info-for-device-matching.patch usb/usb-ehci-fix-handover-for-designated-full-speed-ports.patch usb/usb-ehci-ohci-handover-changes.patch usb/usb-gadget-driver-for-samsung-s3c2410-arm-soc.patch usb/usb-io_ti-digi-edgeport-update-for-new-devices.patch usb/usb-option-fix-usage-of-urb-status-abuse.patch usb/usb-oti6858-usb-serial-driver.patch usb/usb-prevent-char-device-open-deregister-race.patch usb/usb-rework-c-style-comments.patch usb/usb-usb-gadget-dead-config-cleanup.patch usb/usbmon-add-class-for-binary-interface.patch usb/usb-usb-host-side-can-be-configured-given-pcmcia.patch usb/ehci-hub-improved-over-current-recovery.patch usb/usb-ehci-big-endian-data-structures-support.patch usb/usb-export-linux-usb_gadgetfs-as-linux-usb-gadgetfs.h.patch usb/usb-ir-usb-status.patch usb/usb-set-config_usb_ehci_big_endian_mmio-_desc-in-usb-host-kconfig.patch usb/pl2303.c-patch.patch usb/usb-usb-storage-use-kthread_stop-for-the-control-thread.patch usb/usb-keyspan-status.patch usb/usb-keyspan_pda-status.patch usb/usb-handle-bogus-low-speed-bulk-endpoints.patch usb/usb-free-dma-mappings-if-enqueue-fails.patch usb/usb-kl5kusb105-status.patch usb/usb-kobil_sct-status.patch usb/usb-mct_u232-status.patch usb/usb-mos7720-status.patch usb/usb-mos7840-status.patch usb/usb-navman-status.patch usb/usb-omninet-status.patch usb/usb-option-status.patch usb/usb-oti6858-status.patch usb/usb-pl2303-status.patch usb/usb-safe_serial-status.patch usb/usb-sierra-status.patch usb/usb-ti_usb_3410_5052-status.patch usb/usb-visor-status.patch usb/usb-whiteheat-status.patch HOWTO ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel