25 Apr, 2008

12 commits

  • * git://git.linux-nfs.org/projects/trondmy/nfs-2.6: (80 commits)
    SUNRPC: Invalidate the RPCSEC_GSS session if the server dropped the request
    make nfs_automount_list static
    NFS: remove duplicate flags assignment from nfs_validate_mount_data
    NFS - fix potential NULL pointer dereference v2
    SUNRPC: Don't change the RPCSEC_GSS context on a credential that is in use
    SUNRPC: Fix a race in gss_refresh_upcall()
    SUNRPC: Don't disconnect more than once if retransmitting NFSv4 requests
    SUNRPC: Remove the unused export of xprt_force_disconnect
    SUNRPC: remove XS_SENDMSG_RETRY
    SUNRPC: Protect creds against early garbage collection
    NFSv4: Attempt to use machine credentials in SETCLIENTID calls
    NFSv4: Reintroduce machine creds
    NFSv4: Don't use cred->cr_ops->cr_name in nfs4_proc_setclientid()
    nfs: fix printout of multiword bitfields
    nfs: return negative error value from nfs{,4}_stat_to_errno
    NLM/lockd: Ensure client locking calls use correct credentials
    NFS: Remove the buggy lock-if-signalled case from do_setlk()
    NLM/lockd: Fix a race when cancelling a blocking lock
    NLM/lockd: Ensure that nlmclnt_cancel() returns results of the CANCEL call
    NLM: Remove the signal masking in nlmclnt_proc/nlmclnt_cancel
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://linux-nfs.org/~bfields/linux: (52 commits)
    knfsd: clear both setuid and setgid whenever a chown is done
    knfsd: get rid of imode variable in nfsd_setattr
    SUNRPC: Use unsigned loop and array index in svc_init_buffer()
    SUNRPC: Use unsigned index when looping over arrays
    SUNRPC: Update RPC server's TCP record marker decoder
    SUNRPC: RPC server still uses 2.4 method for disabling TCP Nagle
    NLM: don't let lockd exit on unexpected svc_recv errors (try #2)
    NFS: don't let nfs_callback_svc exit on unexpected svc_recv errors (try #2)
    Use a zero sized array for raw field in struct fid
    nfsd: use static memory for callback program and stats
    SUNRPC: remove svc_create_thread()
    nfsd: fix comment
    lockd: Fix stale nlmsvc_unlink_block comment
    NFSD: Strip __KERNEL__ testing from unexported header files.
    sunrpc: make token header values less confusing
    gss_krb5: consistently use unsigned for seqnum
    NFSD: Remove NFSv4 dependency on NFSv3
    SUNRPC: Remove PROC_FS dependency
    NFSD: Use "depends on" for PROC_FS dependency
    nfsd: move most of fh_verify to separate function
    ...

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/v4l-dvb: (452 commits)
    V4L/DVB (7731): tuner-xc2028: fix signal strength calculus
    V4L/DVB (7730): tuner-xc2028: Fix SCODE load for MTS firmwares
    V4L/DVB (7729): Fix VIDIOCGAP corruption in ivtv
    V4L/DVB (7728): tea5761: bugzilla #10462: tea5761 autodetection code were broken
    V4L/DVB (7726): cx23885: Enable cx23417 support on the HVR1800
    V4L/DVB (7725): cx23885: Add generic cx23417 hardware encoder support
    V4L/DVB (7723): pvrusb2: Clean up input selection list generation in V4L interface
    V4L/DVB (7722): pvrusb2: Implement FM radio support for Gotview USB2.0 DVD 2
    V4L/DVB (7721): pvrusb2: Restructure cx23416 firmware loading to have a common exit point
    V4L/DVB (7720): pvrusb2: Fix bad error code on cx23416 firmware load failure
    V4L/DVB (7719): pvrusb2: Implement input selection enforcement
    V4L/DVB (7718): pvrusb2-dvb: update Kbuild selections
    V4L/DVB (7717): pvrusb2-dvb: add DVB-T support for Hauppauge pvrusb2 model 73xxx
    V4L/DVB (7716): pvrusb2: clean up global functions
    V4L/DVB (7715): pvrusb2: Clean out all use of __FUNCTION__
    V4L/DVB (7714): pvrusb2: Fix hang on module removal
    V4L/DVB (7713): pvrusb2: Implement cleaner DVB kernel thread shutdown
    V4L/DVB (7712): pvrusb2: Close connect/disconnect race
    V4L/DVB (7711): pvrusb2: Fix race on module unload
    V4L/DVB (7710): pvrusb2: Implement critical digital streaming quirk for onair devices
    ...

    Linus Torvalds
     
  • Trond Myklebust
     
  • Adding support for a new i2c bridge type

    Signed-off-by: Steven Toth
    Signed-off-by: Mauro Carvalho Chehab

    Steven Toth
     
  • Define a pre-defined control ID for color killer functionality.

    Signed-off-by: "Frej Drejhammar "
    Signed-off-by: Mauro Carvalho Chehab

    Frej Drejhammar
     
  • Define a pre-defined control ID for chroma automatic gain control.

    Signed-off-by: "Frej Drejhammar "
    Signed-off-by: Mauro Carvalho Chehab

    Frej Drejhammar
     
  • Currently (in linux-2.6.24, but linux-dvb hg looks similar), the
    dmx_output_t in the dmx_pes_filter_params decides two things: whether
    output is sent to demux0 or dvr0 (in dmxdev.c:dvb_dmxdev_ts_callback),
    *and* whether to depacketise TS (in dmxdev.c:dvb_dmxdev_filter_start).
    As it stands, those two things can't be set independently: output
    destined for demux0 is depacketised, output for dvr0 isn't.

    This is what you want for capturing multiple audio streams from the same
    multiplex simultaneously: open demux0 several times and send
    depacketised output there. And capturing a single video stream is fine
    not what you want: you want multi-open (so demux0, not dvr0), but you
    want the TS nature preserved (because that's what you want on output, as
    you're going to re-multiplex it with the audio).

    At least one existing solution -- GStreamer -- sends all its streams
    simultaneously via dvr0 and demuxes again in userland, but it seems a
    bit of a shame to pick out all the PIDs in kernel, stick them back
    together in kernel, and send them to userland only to get unpicked
    again, when the alternative is such a small API addition.

    The attached patch adds a new value for dmx_output_t:
    DMX_OUT_TSDEMUX_TAP, which sends TS to the demux0 device. With this
    patch and a dvb-usb-dib0700 (and UK Freeview from Sandy Heath), I can
    successfully capture an audio/video PID pair into a TS file that mplayer
    can play back.

    Signed-off-by: Peter Hartley
    Acked-by: Andreas Oberritter
    Signed-off-by: Mauro Carvalho Chehab

    Peter Hartley
     
  • - Continue to support the V4L2_CID_PRIVATE_BASE + 1 control in the ABI
    - Report the same control as V4L2_CID_SHARPNESS
    - Report the private control disabled via QUERYCTRL

    Signed-off-by: Brandon Philips
    Acked-by: Stelian Pop
    Signed-off-by: Mauro Carvalho Chehab

    Brandon Philips
     
  • This adds two new fourcc codes (as per info at fourcc.org)
    for 16bpp mono and 16bpp Bayer formats.

    Signed-off-by: Steven Whitehouse
    Signed-off-by: Guennadi Liakhovetski
    Signed-off-by: Mauro Carvalho Chehab

    Steven Whitehouse
     
  • Add all of the recently proposed camera class controls. These controls
    should appear in the next version of the v4l2spec.

    Signed-off-by: Brandon Philips
    Signed-off-by: Mauro Carvalho Chehab

    Brandon Philips
     
  • These changes should appear in the next update of the v4l2spec.

    HCENTER and VCENTER are unused in the tree so I added a _DEPRECATED
    postfix so applications can remove their use.

    Signed-off-by: Brandon Philips
    Signed-off-by: Mauro Carvalho Chehab

    Brandon Philips
     

24 Apr, 2008

13 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (22 commits)
    tun: Multicast handling in tun_chr_ioctl() needs proper locking.
    [NET]: Fix heavy stack usage in seq_file output routines.
    [AF_UNIX] Initialise UNIX sockets before general device initcalls
    [RTNETLINK]: Fix bogus ASSERT_RTNL warning
    iwlwifi: Fix built-in compilation of iwlcore (part 2)
    tun: Fix minor race in TUNSETLINK ioctl handling.
    ppp_generic: use stats from net_device structure
    iwlwifi: Don't unlock priv->mutex if it isn't locked
    wireless: rndis_wlan: modparam_workaround_interval is never below 0.
    prism54: prism54_get_encode() test below 0 on unsigned index
    mac80211: update mesh EID values
    b43: Workaround DMA quirks
    mac80211: fix use before check of Qdisc length
    net/mac80211/rx.c: fix off-by-one
    mac80211: Fix race between ieee80211_rx_bss_put and lookup routines.
    ath5k: Fix radio identification on AR5424/2424
    ssb: Fix all-ones boardflags
    b43: Add more btcoexist workarounds
    b43: Fix HostFlags data types
    b43: Workaround invalid bluetooth settings
    ...

    Linus Torvalds
     
  • ASSERT_RTNL uses mutex_trylock to test whether the rtnl_mutex is
    held. This bogus warnings when running in atomic context, which
    f.e. happens when adding secondary unicast addresses through
    macvlan or vlan or when synchronizing multicast addresses from
    wireless devices.

    Mid-term we might want to consider moving all address updates
    to process context since the locking seems overly complicated,
    for now just fix the bogus warning by changing ASSERT_RTNL to
    use mutex_is_locked().

    Signed-off-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Patrick McHardy
     
  • This patch updates mesh EID values, some of which where conflicting with
    already-approved 11h EIDs (pointed out by Tomas Winkler). I wanted to use the
    values suggested in the last available 802.11 draft (2.0) but it assigns 50 to
    MESH_CONFIG, the same value than EXT_SUPP_RATES. Using the values proposed in
    the draft incremented by one.

    Signed-off-by: Luis Carlos Cobo
    Signed-off-by: John W. Linville

    Luis Carlos Cobo
     
  • Clean up: Update the RPC server's TCP record marker decoder to match the
    constructs used by the RPC client's TCP socket transport.

    Signed-off-by: Chuck Lever
    Signed-off-by: J. Bruce Fields

    Chuck Lever
     
  • The raw field's size can vary so we use a zero sized array since
    gcc will not allow a variable sized array inside a union. This
    has been tested with ext3 and gfs2 and relates to the bug
    report: http://lkml.org/lkml/2007/10/24/374 and discussion
    thread: http://lkml.org/lkml/2008/4/7/65

    Signed-off-by: Steven Whitehouse
    Cc: Christoph Hellwig
    Cc: Neil Brown
    Cc: Adrian Bunk
    Signed-off-by: J. Bruce Fields

    Steven Whitehouse
     
  • Now that the nfs4 callback thread uses the kthread API, there are no
    more users of svc_create_thread(). Remove it.

    Signed-off-by: Jeff Layton
    Signed-off-by: J. Bruce Fields

    Jeff Layton
     
  • Also, sort the Kbuild file.

    Signed-off-by: Robert P. J. Day
    Signed-off-by: J. Bruce Fields

    Robert P. J. Day
     
  • Consistently use unsigned (u32 vs. s32) for seqnum.

    In get_mic function, send the local copy of seq_send,
    rather than the context version.

    Signed-off-by: Kevin Coffman
    Signed-off-by: J. Bruce Fields

    Kevin Coffman
     
  • cleanup: When adding new encryption types, the checksum length
    can be different for each enctype. Face the fact that the
    current code only supports DES which has a checksum length of 8.

    Signed-off-by: Kevin Coffman
    Signed-off-by: J. Bruce Fields

    Kevin Coffman
     
  • Add extern to nfsd/nfsd.h
    fs/nfsd/nfssvc.c:146:5: warning: symbol 'nfsd_nrthreads' was not declared. Should it be static?
    fs/nfsd/nfssvc.c:261:5: warning: symbol 'nfsd_nrpools' was not declared. Should it be static?
    fs/nfsd/nfssvc.c:269:5: warning: symbol 'nfsd_get_nrthreads' was not declared. Should it be static?
    fs/nfsd/nfssvc.c:281:5: warning: symbol 'nfsd_set_nrthreads' was not declared. Should it be static?
    fs/nfsd/export.c:1534:23: warning: symbol 'nfs_exports_op' was not declared. Should it be static?

    Add include of auth.h
    fs/nfsd/auth.c:27:5: warning: symbol 'nfsd_setuser' was not declared. Should it be static?

    Make static, move forward declaration closer to where it's needed.
    fs/nfsd/nfs4state.c:1877:1: warning: symbol 'laundromat_main' was not declared. Should it be static?

    Make static, forward declaration was already marked static.
    fs/nfsd/nfs4idmap.c:206:1: warning: symbol 'idtoname_parse' was not declared. Should it be static?
    fs/nfsd/vfs.c:1156:1: warning: symbol 'nfsd_create_setattr' was not declared. Should it be static?

    Signed-off-by: Harvey Harrison
    Signed-off-by: J. Bruce Fields

    Harvey Harrison
     
  • This field is set once and never used; probably some artifact of an
    earlier implementation idea.

    Signed-off-by: J. Bruce Fields

    J. Bruce Fields
     
  • Thanks to Robert Day for pointing out that these two defines are unused.

    Signed-off-by: J. Bruce Fields
    Cc: Trond Myklebust Trond Myklebust
    Cc: Neil Brown
    Cc: "Robert P. J. Day"

    J. Bruce Fields
     
  • This adds IPv6 support to the interfaces that are used to express nfsd
    exports. All addressed are stored internally as IPv6; backwards
    compatibility is maintained using mapped addresses.

    Thanks to Bruce Fields, Brian Haley, Neil Brown and Hideaki Joshifuji
    for comments

    Signed-off-by: Aurelien Charbon
    Cc: Neil Brown
    Cc: Brian Haley
    Cc: YOSHIFUJI Hideaki / 吉藤英明
    Signed-off-by: J. Bruce Fields

    Aurélien Charbon
     

23 Apr, 2008

13 commits

  • [mszeredi@suse.cz] rewrite and split big patch into managable chunks

    /proc/mounts in its current form lacks important information:

    - propagation state
    - root of mount for bind mounts
    - the st_dev value used within the filesystem
    - identifier for each mount and it's parent

    It also suffers from the following problems:

    - not easily extendable
    - ambiguity of mountpoints within a chrooted environment
    - doesn't distinguish between filesystem dependent and independent options
    - doesn't distinguish between per mount and per super block options

    This patch introduces /proc//mountinfo which attempts to address
    all these deficiencies.

    Code shared between /proc//mounts and /proc//mountinfo is
    extracted into separate functions.

    Thanks to Al Viro for the help in getting the design right.

    Signed-off-by: Ram Pai
    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Ram Pai
     
  • Allow /proc//mountinfo to use the root of to calculate
    mountpoints.

    - move definition of 'struct proc_mounts' to
    - add the process's namespace and root to this structure
    - pass a pointer to 'struct proc_mounts' into seq_operations

    In addition the following cleanups are made:

    - use a common open function for /proc//{mounts,mountstat}
    - surround namespace.c part of these proc files with #ifdef CONFIG_PROC_FS
    - make the seq_operations structures const

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Miklos Szeredi
     
  • Add a unique ID to each peer group using the IDR infrastructure. The
    identifiers are reused after the peer group dissolves.

    The IDR structures are protected by holding namepspace_sem for write
    while allocating or deallocating IDs.

    IDs are allocated when a previously unshared vfsmount becomes the
    first member of a peer group. When a new member is added to an
    existing group, the ID is copied from one of the old members.

    IDs are freed when the last member of a peer group is unshared.

    Setting the MNT_SHARED flag on members of a subtree is done as a
    separate step, after all the IDs have been allocated. This way an
    allocation failure can be cleaned up easilty, without affecting the
    propagation state.

    Based on design sketch by Al Viro.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Miklos Szeredi
     
  • Add a unique ID to each vfsmount using the IDR infrastructure. The
    identifiers are reused after the vfsmount is freed.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Miklos Szeredi
     
  • Add a new function:

    seq_file_root()

    This is similar to seq_path(), but calculates the path relative to the
    given root, instead of current->fs->root. If the path was unreachable
    from root, then modify the root parameter to reflect this.

    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Miklos Szeredi
     
  • [mszeredi@suse.cz] split big patch into managable chunks

    Add the following functions:

    dentry_path()
    seq_dentry()

    These are similar to d_path() and seq_path(). But instead of
    calculating the path within a mount namespace, they calculate the path
    from the root of the filesystem to a given dentry, ignoring mounts
    completely.

    Signed-off-by: Ram Pai
    Signed-off-by: Miklos Szeredi
    Signed-off-by: Al Viro

    Ram Pai
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
    [PATCH] get rid of __exit_files(), __exit_fs() and __put_fs_struct()
    [PATCH] proc_readfd_common() race fix
    [PATCH] double-free of inode on alloc_file() failure exit in create_write_pipe()
    [PATCH] teach seq_file to discard entries
    [PATCH] umount_tree() will unhash everything itself
    [PATCH] get rid of more nameidata passing in namespace.c
    [PATCH] switch a bunch of LSM hooks from nameidata to path
    [PATCH] lock exclusively in collect_mounts() and drop_collected_mounts()
    [PATCH] move a bunch of declarations to fs/internal.h

    Linus Torvalds
     
  • * 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
    i2c: Fix platform driver hotplug/coldplug
    i2c: New driver for the SuperH Mobile I2C bus controller
    i2c/scx200_acb: Don't use 0 as NULL pointer
    i2c-bfin-twi: Fix mismatch in add timer and delete timer
    i2c-bfin-twi: Just let i2c-bfin-twi driver depends on BLACKFIN
    i2c-bfin-twi: Use simpler comment headers and strip out information that is maintained in the scm's log
    i2c-bfin-twi: Cleanup driver descriptions, versions and some module useful information
    i2c-bfin-twi: Add missing pin mux operation
    i2c-bfin-twi: Add platform_resource interface to support multi-port TWI controllers
    i2c-bfin-twi: Add repeat start feature to avoid break of a bundle of i2c master xfer operation
    i2c: Remove trailing whitespaces in busses/Kconfig
    i2c: Replace remaining __FUNCTION__ occurrences
    i2c: Renesas SH7760 I2C master driver
    i2c-dev: Split i2cdev_ioctl
    i2c-ibm_iic: Support building as an of_platform driver
    i2c-ibm_iic: Change the log levels
    i2c: Add platform driver on top of the new pca-algorithm
    i2c-algo-pca: Extend for future drivers
    i2c-algo-pca: Remove trailing whitespaces and unnecessary UTF
    i2c: Remove the algorithm drivers from the config menu

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/teigland/dlm:
    dlm: linux/{dlm,dlm_device}.h: cleanup for userspace
    dlm: common max length definitions
    dlm: move plock code from gfs2
    dlm: recover nodes that are removed and re-added
    dlm: save master info after failed no-queue request
    dlm: make dlm_print_rsb() static
    dlm: match signedness between dlm_config_info and cluster_set

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
    HID: Suppress hidinput for Samsung IR control
    HID: remove 60x GTCO devices from blacklist
    HID: export headers properly
    HID: WiseGroup 866 Dual Joypad needs output reports quirk
    HID: ThrustMaster FF driver is no longer experimental
    HID: Logitech diNovo Mini pad support
    HID: fix race between open() and disconnect() in usbhid
    HID: make hid_input_field and usbhid_modify_dquirk static
    HID: pass numbered reports properly to hidraw
    HID: fix misplaced rdesc quirk
    HID: force feedback driver for Logitech Rumblepad 2
    HID: move wait from hid to usbhid
    HID: make function from dbg_hid
    HID: fix sparse warnings
    HID: only dump report traffic with debug level 2
    HID: patch to add NOGET for DMI/Acomdata
    HID: Sunplus Wireless Desktop needs report descriptor fixup
    HID: quirk for MS Wireless Desktop Receiver (model 1028)
    HID: fixup fullspeed interval on highspeed Afatech DVB-T IR kbd
    HID: fix build failure in hiddev_ioctl with gcc 3.2

    Linus Torvalds
     
  • * 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-udf-2.6: (41 commits)
    udf: use crc_itu_t from lib instead of udf_crc
    udf: Fix compilation warnings when UDF debug is on
    udf: Fix bug in VAT mapping code
    udf: Add read-only support for 2.50 UDF media
    udf: Fix handling of multisession media
    udf: Mount filesystem read-only if it has pseudooverwrite partition
    udf: Handle VAT packed inside inode properly
    udf: Allow loading of VAT inode
    udf: Fix detection of VAT version
    udf: Silence warning about accesses beyond end of device
    udf: Improve anchor block detection
    udf: Cleanup anchor block detection.
    udf: Move processing of virtual partitions
    udf: Move filling of partition descriptor info into a separate function
    udf: Improve error recovery on mount
    udf: Cleanup volume descriptor sequence processing
    udf: fix anchor point detection
    udf: Remove declarations of arrays of size UDF_NAME_LEN (256 bytes)
    udf: Remove checking of existence of filename in udf_add_entry()
    udf: Mark udf_process_sequence() as noinline
    ...

    Linus Torvalds
     
  • Tested on a blackfin.

    Signed-off-by: Wolfram Sang
    Signed-off-by: Jean Delvare

    Wolfram Sang
     
  • The separation between algorithm and adapter was unsharp at places. This was
    partly hidden by the fact, that the ISA-driver allowed just one instance and
    had all private data in static variables. This patch makes neccessary
    preparations to add a platform driver on top of the algorithm, while still
    supporting ISA. Note: Due to lack of hardware, the ISA-driver could not be
    tested except that it builds.

    Concerning the core struct i2c_algo_pca_data:

    - A private data field was added, all hardware dependant data may go here.
    Similar to other algorithms, now a pointer to this data is passed to the
    adapter's functions. In order to make as less changes as possible to the
    ISA-driver, it leaves the private data empty and still only uses its static
    variables.

    - A "reset_chip" function pointer was added; such a functionality must come
    from the adapter, not the algorithm.

    - use a variable "i2c_clock" instead of a function pointer "get_clock",
    allowing for write access to a default in case a wrong value was supplied.

    In the algorithm-file:

    - move "i2c-pca-algo.h" into "linux/i2c-algo-pca.h"
    - now using per_instance timeout values (i2c_adap->timeout)
    - error messages specify the device, not only the driver name
    - restructure initialization to easily support "i2c_add_numbered_adapter"
    - drop "retries" and "own" (i2c address) as they were unused

    (The state-machine for I2C-communication was not touched.)

    In the ISA-driver:

    - adapt to new algorithm

    Signed-off-by: Wolfram Sang
    Signed-off-by: Jean Delvare

    Wolfram Sang
     

22 Apr, 2008

2 commits

  • I have people whining about using these headers in userspace, and they have
    __KERNEL__ markings which implies they're supposed to be exported. I also
    added the required linux/types.h include to hidraw.h since it uses the __u##
    kernel types.

    Signed-off-by: Mike Frysinger
    Cc: Jiri Kosina
    Cc: Dmitry Torokhov
    Signed-off-by: Andrew Morton
    Signed-off-by: Jiri Kosina

    Mike Frysinger
     
  • There is a window:

    task A task B
    spin_lock_irq(&usbhid->inlock); /* Sync with error handler */
    usb_set_intfdata(intf, NULL);
    spin_unlock_irq(&usbhid->inlock);
    usb_kill_urb(usbhid->urbin);
    usb_kill_urb(usbhid->urbout);
    usb_kill_urb(usbhid->urbctrl);

    del_timer_sync(&usbhid->io_retry);
    cancel_work_sync(&usbhid->reset_work);

    if (!hid->open++) {
    res = usb_autopm_get_interface(usbhid->intf);
    if (res < 0) {
    hid->open--;
    return -EIO;
    }
    }
    if (hid_start_in(hid))

    if (hid->claimed & HID_CLAIMED_INPUT)
    hidinput_disconnect(hid);

    in which an open() to an already disconnected device will submit an URB
    to an undead device. In case disconnect() was called by an ioctl, this'll
    oops. Fix by introducing a new flag and checking it in hid_start_in().

    Signed-off-by: Oliver Neukum
    Signed-off-by: Jiri Kosina

    Oliver Neukum