24 Oct, 2011

23 commits

  • Testing in_interrupt() to know when sleeping is allowed is not really
    reliable (since eg it won't be true if the caller is holding a spinlock).
    Instead have the caller tell core_tmr_alloc_req() what GFP_xxx to use;
    every caller except tcm_qla2xxx can use GFP_KERNEL.

    Signed-off-by: Roland Dreier
    Signed-off-by: Nicholas Bellinger

    Roland Dreier
     
  • This patch changes pscsi_create_virtdevice() to properly return ERR_CAST
    instead of a raw pointer upon scsi_host_lookup() failure.

    Signed-off-by: Dan Carpenter
    Signed-off-by: Nicholas Bellinger

    Dan Carpenter
     
  • This patch converts ft_parse_wwn() to use hex_to_bin() instead of custom
    conversion code.

    (Andy: Re-add missing strict && isupper(c) check)

    Signed-off-by: Andy Shevchenko
    Cc: "Nicholas A. Bellinger"
    Signed-off-by: Nicholas Bellinger

    Andy Shevchenko
     
  • This patch converts chap_string_to_hex() to use hex2bin() instead of
    the internal chap_asciihex_to_binaryhex().

    (nab: Fix up minor compile breakage + typo)

    Signed-off-by: Andy Shevchenko
    Cc: "Nicholas A. Bellinger"
    Signed-off-by: Nicholas Bellinger

    Andy Shevchenko
     
  • The cdb_none, map_data_SG and map_control_SG methods have no callers left
    and can be removed now.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Move the entirely request allocation, mapping and submission into ->do_task.
    This

    a) avoids blocking the I/O submission thread unessecarily, and
    b) simplifies the code greatly

    Note that the code seems to have various error handling issues, mostly
    related to bidi handling in the current form. I've added comments about
    those but not tried to fix them in this commit.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Move the entirely bio allocation, mapping and submission into ->do_task.
    This

    a) avoids blocking the I/O submission thread unessecarily, and
    b) simplifies the code greatly

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • This patch adds a minor simplfication in target_parse_naa_6h_vendor_specific()
    to remove direct isxdigit() + ctype.h usage.

    (nab: Fix next assignment breakage in for loop)

    Signed-off-by: Andy Shevchenko
    Cc: Nicholas Bellinger
    Signed-off-by: Nicholas Bellinger

    Andy Shevchenko
     
  • This patch removes the unnecessary session_reinstatement parameter from
    se_cmd->transport_wait_for_tasks(), logic in transport_generic_wait_for_tasks,
    and usage within iscsi-target code.

    This also includes the removal of the 'bool' return from transport_put_cmd() +
    transport_generic_free_cmd() that is no longer necessary.

    Cc: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Nicholas Bellinger
     
  • Push session reinstatement out of transport_generic_free_cmd into the only
    caller that actually needs it. Clean up transport_generic_free_cmd a bit,
    and remove the useless comment. I'd love to add a more useful kerneldoc
    comment for it, but as this point I'm still a bit confused in where it
    stands in the command release stack.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • All callers that never have the session_reinstatement flag set can trivially
    be converted to transport_put_cmd. Opencode the session reinstatement code
    in transport_generic_free_cmd, which was the only caller ever asking for it.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Inline two simple functions only used by it, and replace a goto
    with a simple if else construct.

    Note that the code moved from transport_dec_and_check seems fairly
    buggy - the atomic_read check on a variable where we'd do an
    atomic_dec_and_test looks racy if we'll ever get someone increment
    it without the lock held around them (which it looks like we do),
    and not decrementing the second counter if the first one doesn't
    hit zero also at least needs an explanation.

    (nab: Fix transport_put_cmd breakage)

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Instead of duplicating the code from transport_release_fe_cmd re-use it by
    allowing transport_release_fe_cmd to return wether it actually freed the
    command or not. Also rename transport_release_fe_cmd to transport_put_cmd
    and add a kerneldoc comment for it to make the use case more obvious.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • It is only called by transport_release_cmd, so inline it there. Also add
    a kerneldoc comment for transport_release_cmd while we are at it.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • iscsit_task_reassign_complete is always called from the TX thread, so
    handle the CDB directly instead of offloading it.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • ft_send_work is always called from workqueue context, which means we can
    handle the CDB directly instead of doing another context switch.

    Signed-off-by: Christoph Hellwig
    Cc: Kiran Patil
    Signed-off-by: Nicholas Bellinger

    Christoph Hellwig
     
  • This patch fixes a bug where transport_send_task_abort() could be called
    during LUN_RESET to return SAM_STAT_TASK_ABORTED + tfo->queue_status(), when
    SCF_SENT_CHECK_CONDITION -> tfo->queue_status() has already been sent from
    within another context via transport_send_check_condition_and_sense().

    Cc: stable@kernel.org
    Signed-off-by: Nicholas Bellinger

    Nicholas Bellinger
     
  • This patch fixes a bug in LUN_RESET operation with transport_cmd_finish_abort()
    where transport_remove_cmd_from_queue() was incorrectly being called, causing
    descriptors with t_state == TRANSPORT_FREE_CMD_INTR to be incorrectly removed
    from qobj->qobj_list during process context release. This change ensures the
    descriptor is only removed via transport_remove_cmd_from_queue() when doing a
    direct release via transport_generic_remove().

    Cc: stable@kernel.org
    Signed-off-by: Nicholas Bellinger

    Nicholas Bellinger
     
  • This patch contains a bugfix for TMR LUN_RESET related to TRANSPORT_FREE_CMD_INTR
    operation, where core_tmr_drain_cmd_list() will now skip processing for this
    case to prevent an ABORT_TASK status from being returned for descriptors that
    are already queued up to be released by processing thread context.

    Cc: Roland Dreier
    Cc: Christoph Hellwig
    Cc: stable@kernel.org
    Signed-off-by: Nicholas Bellinger

    Nicholas Bellinger
     
  • This patch is a re-orginzation of core_tmr_lun_reset() logic to properly
    scan the active tmr_list, dev->state_task_list and qobj->qobj_list w/ the
    relivent locks held, and performing a list_move_tail onto seperate local
    scope lists before performing the full drain.

    This involves breaking out the code into three seperate list specific
    functions: core_tmr_drain_tmr_list(), core_tmr_drain_task_list() and
    core_tmr_drain_cmd_list().

    (nab: Include target: Remove non-active tasks from execute list during
    LUN_RESET patch to address original breakage)

    Reported-by: Roland Dreier
    Cc: Roland Dreier
    Cc: Christoph Hellwig
    Cc: stable@kernel.org
    Signed-off-by: Nicholas Bellinger

    Nicholas Bellinger
     
  • This patch addresses a bug with the lio-core-2.6.git conversion of
    transport_add_cmd_to_queue() to use a single embedded list_head, instead
    of individual struct se_queue_req allocations allowing a single se_cmd to
    be added to the queue mulitple times. This was changed in the following:

    commit 2a9e4d5ca5d99f4c600578d6285d45142e7e5208
    Author: Andy Grover
    Date: Tue Apr 26 17:45:51 2011 -0700

    target: Embed qr in struct se_cmd

    The problem is that some target code still assumes performing multiple
    adds is allowed via transport_add_cmd_to_queue(), which ends up causing
    list corruption in qobj->qobj_list code. This patch addresses this
    by removing an existing struct se_cmd from the list before the add, and
    removes an unnecessary list walk in transport_remove_cmd_from_queue()

    It also changes cmd->t_transport_queue_active to use explict sets intead
    of increment/decrement to prevent confusion during exception path handling.

    Signed-off-by: Roland Dreier
    Cc: Andy Grover
    Cc: stable@kernel.org
    Signed-off-by: Nicholas Bellinger

    Roland Dreier
     

11 Oct, 2011

1 commit


10 Oct, 2011

6 commits

  • * git://git.samba.org/sfrench/cifs-2.6:
    [CIFS] Fix first time message on mount, ntlmv2 upgrade delayed to 3.2

    Linus Torvalds
     
  • * 'fixes' of git://git.linaro.org/people/arnd/arm-soc:
    ARM: mach-ux500: enable fix for ARM errata 754322
    ARM: OMAP: musb: Remove a redundant omap4430_phy_init call in usb_musb_init
    ARM: OMAP: Fix i2c init for twl4030
    ARM: OMAP4: MMC: fix power and audio issue, decouple USBC1 from MMC1

    Linus Torvalds
     
  • This fixes a compilation error in cpu-tegra.c which was introduced in
    dc8d966bccde ("ARM: convert PCI defines to variables") which removed the
    now obsolete mach/hardware.h from the mach-tegra subtree.

    Signed-off-by: Marc Dietrich
    Signed-off-by: Olof Johansson
    Cc: Sergei Shtylyov
    Signed-off-by: Linus Torvalds

    Marc Dietrich
     
  • * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
    drm/radeon/kms: use hardcoded dig encoder to transmitter mapping for DCE4.1
    drm/radeon/kms: fix dp_detect handling for DP bridge chips
    drm/radeon/kms: retry aux transactions if there are status flags

    Linus Torvalds
     
  • A couple of changes to the Tegra maintainership setup:

    I'm very glad to bring on Stephen Warren on board as a maintainer. The
    work he has done so far is excellent, and the fact that he works for
    Nvidia means he has long-term interest in the platform.

    Erik Gilling did an astounding amount of work on getting things up and
    running but has been a silent partner on the maintainership side for a
    while, and is stepping down. Thanks for your contributions so far, Erik.

    Finally, update the git URL since I'll take over running the main repo
    for a while.

    Overall maintainership model isn't changing much at this time: We'll all
    three review patches as appropriate, and one of us will collect the main
    repo (me at this time).

    Signed-off-by: Olof Johansson
    Cc: Erik Gilling
    Acked-by: Colin Cross
    Acked-by: Stephen Warren
    Signed-off-by: Linus Torvalds

    Olof Johansson
     
  • * 'upstream' of git://git.linux-mips.org/pub/scm/upstream-linus: (29 commits)
    MIPS: Call oops_enter, oops_exit in die
    staging/octeon: Software should check the checksum of no tcp/udp packets
    MIPS: Octeon: Enable C0_UserLocal probing.
    MIPS: No branches in delay slots for huge pages in handle_tlbl
    MIPS: Don't clobber CP0_STATUS value for CONFIG_MIPS_MT_SMTC
    MIPS: Octeon: Select CONFIG_HOLES_IN_ZONE
    MIPS: PM: Use struct syscore_ops instead of sysdevs for PM (v2)
    MIPS: Compat: Use 32-bit wrapper for compat_sys_futex.
    MIPS: Do not use EXTRA_CFLAGS
    MIPS: Alchemy: DB1200: Disable cascade IRQ in handler
    SERIAL: Lantiq: Set timeout in uart_port
    MIPS: Lantiq: Fix setting the PCI bus speed on AR9
    MIPS: Lantiq: Fix external interrupt sources
    MIPS: tlbex: Fix build error in R3000 code.
    MIPS: Alchemy: Include Au1100 in PM code.
    MIPS: Alchemy: Fix typo in MAC0 registration
    MIPS: MSP71xx: Fix build error.
    MIPS: Handle __put_user() sleeping.
    MIPS: Allow forced irq threading
    MIPS: i8259: Mark cascade interrupt non-threaded
    ...

    Linus Torvalds
     

09 Oct, 2011

1 commit


08 Oct, 2011

1 commit


07 Oct, 2011

5 commits

  • This applies ARM errata fix 754322 for all ux500 platforms.

    Cc: stable@kernel.org
    Signed-off-by: srinidhi kasagar
    Signed-off-by: Linus Walleij

    srinidhi kasagar
     
  • * git://github.com/davem330/net:
    net: fix typos in Documentation/networking/scaling.txt
    bridge: leave carrier on for empty bridge
    netfilter: Use proper rwlock init function
    tcp: properly update lost_cnt_hint during shifting
    tcp: properly handle md5sig_pool references
    macvlan/macvtap: Fix unicast between macvtap interfaces in bridge mode

    Linus Torvalds
     
  • In summary, this DMI quirk uses the _CRS info by default for the ASUS
    M2V-MX SE by turning on `pci=use_crs` and is similar to the quirk
    added by commit 2491762cfb47 ("x86/PCI: use host bridge _CRS info on
    ASRock ALiveSATA2-GLAN") whose commit message should be read for further
    information.

    Since commit 3e3da00c01d0 ("x86/pci: AMD one chain system to use pci
    read out res") Linux gives the following oops:

    parport0: PC-style at 0x378, irq 7 [PCSPP,TRISTATE]
    HDA Intel 0000:20:01.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
    HDA Intel 0000:20:01.0: setting latency timer to 64
    BUG: unable to handle kernel paging request at ffffc90011c08000
    IP: [] azx_probe+0x3ad/0x86b [snd_hda_intel]
    PGD 13781a067 PUD 13781b067 PMD 1300ba067 PTE 800000fd00000173
    Oops: 0009 [#1] SMP
    last sysfs file: /sys/module/snd_pcm/initstate
    CPU 0
    Modules linked in: snd_hda_intel(+) snd_hda_codec snd_hwdep snd_pcm_oss snd_mixer_oss snd_pcm snd_seq_midi snd_rawmidi snd_seq_midi_event tpm_tis tpm snd_seq tpm_bios psmouse parport_pc snd_timer snd_seq_device parport processor evdev snd i2c_viapro thermal_sys amd64_edac_mod k8temp i2c_core soundcore shpchp pcspkr serio_raw asus_atk0110 pci_hotplug edac_core button snd_page_alloc edac_mce_amd ext3 jbd mbcache sha256_generic cryptd aes_x86_64 aes_generic cbc dm_crypt dm_mod raid1 md_mod usbhid hid sg sd_mod crc_t10dif sr_mod cdrom ata_generic uhci_hcd sata_via pata_via libata ehci_hcd usbcore scsi_mod via_rhine mii nls_base [last unloaded: scsi_wait_scan]
    Pid: 1153, comm: work_for_cpu Not tainted 2.6.37-1-amd64 #1 M2V-MX SE/System Product Name
    RIP: 0010:[] [] azx_probe+0x3ad/0x86b [snd_hda_intel]
    RSP: 0018:ffff88013153fe50 EFLAGS: 00010286
    RAX: ffffc90011c08000 RBX: ffff88013029ec00 RCX: 0000000000000006
    RDX: 0000000000000000 RSI: 0000000000000246 RDI: 0000000000000246
    RBP: ffff88013341d000 R08: 0000000000000000 R09: 0000000000000040
    R10: 0000000000000286 R11: 0000000000003731 R12: ffff88013029c400
    R13: 0000000000000000 R14: 0000000000000000 R15: ffff88013341d090
    FS: 0000000000000000(0000) GS:ffff8800bfc00000(0000) knlGS:00000000f7610ab0
    CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b
    CR2: ffffc90011c08000 CR3: 0000000132f57000 CR4: 00000000000006f0
    DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
    DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
    Process work_for_cpu (pid: 1153, threadinfo ffff88013153e000, task ffff8801303c86c0)
    Stack:
    0000000000000005 ffffffff8123ad65 00000000000136c0 ffff88013029c400
    ffff8801303c8998 ffff88013341d000 ffff88013341d090 ffff8801322d9dc8
    ffff88013341d208 0000000000000000 0000000000000000 ffffffff811ad232
    Call Trace:
    [] ? __pm_runtime_set_status+0x162/0x186
    [] ? local_pci_probe+0x49/0x92
    [] ? do_work_for_cpu+0x0/0x1b
    [] ? do_work_for_cpu+0x0/0x1b
    [] ? do_work_for_cpu+0xb/0x1b
    [] ? kthread+0x7a/0x82
    [] ? kernel_thread_helper+0x4/0x10
    [] ? kthread+0x0/0x82
    [] ? kernel_thread_helper+0x0/0x10
    Code: f4 01 00 00 ef 31 f6 48 89 df e8 29 dd ff ff 85 c0 0f 88 2b 03 00 00 48 89 ef e8 b4 39 c3 e0 8b 7b 40 e8 fc 9d b1 e0 48 8b 43 38 8b 10 66 89 14 24 8b 43 14 83 e8 03 83 f8 01 77 32 31 d2 be
    RIP [] azx_probe+0x3ad/0x86b [snd_hda_intel]
    RSP
    CR2: ffffc90011c08000
    ---[ end trace 8d1f3ebc136437fd ]---

    Trusting the ACPI _CRS information (`pci=use_crs`) fixes this problem.

    $ dmesg | grep -i crs # with the quirk
    PCI: Using host bridge windows from ACPI; if necessary, use "pci=nocrs" and report a bug

    The match has to be against the DMI board entries though since the vendor entries are not populated.

    DMI: System manufacturer System Product Name/M2V-MX SE, BIOS 0304 10/30/2007

    This quirk should be removed when `pci=use_crs` is enabled for machines
    from 2006 or earlier or some other solution is implemented.

    Using coreboot [1] with this board the problem does not exist but this
    quirk also does not affect it either. To be safe though the check is
    tightened to only take effect when the BIOS from American Megatrends is
    used.

    15:13 < ruik> but coreboot does not need that
    15:13 < ruik> because i have there only one root bus
    15:13 < ruik> the audio is behind a bridge

    $ sudo dmidecode
    BIOS Information
    Vendor: American Megatrends Inc.
    Version: 0304
    Release Date: 10/30/2007

    [1] http://www.coreboot.org/

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=30552

    Cc: stable@kernel.org (2.6.34)
    Cc: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: H. Peter Anvin
    Cc: x86@kernel.org
    Signed-off-by: Paul Menzel
    Signed-off-by: Bjorn Helgaas
    Acked-by: Jesse Barnes
    Signed-off-by: Linus Torvalds

    Paul Menzel
     
  • The second hunk fixes rps_sock_flow_table but has to re-wrap the paragraph.

    Signed-off-by: Benjamin Poirier
    Signed-off-by: David S. Miller

    Benjamin Poirier
     
  • This resolves a regression seen by some users of bridging.
    Some users use the bridge like a dummy device.
    They expect to be able to put an IPv6 address on the device
    with no ports attached. Although there are better ways of doing
    this, there is no reason to not allow it.

    Note: the bridge still will reflect the state of ports in the
    bridge if there are any added.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    stephen hemminger
     

06 Oct, 2011

3 commits