1. 04 May, 2011 12 commits
  2. 03 May, 2011 15 commits
  3. 02 May, 2011 13 commits
    • Lucian Adrian Grijincu's avatar
      sysctl: net: call unregister_net_sysctl_table where needed · ff538818
      Lucian Adrian Grijincu authored
      ctl_table_headers registered with register_net_sysctl_table should
      have been unregistered with the equivalent unregister_net_sysctl_table
      Signed-off-by: default avatarLucian Adrian Grijincu <lucian.grijincu@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ff538818
    • Jiri Pirko's avatar
      Revert: veth: remove unneeded ifname code from veth_newlink() · 6c8c4446
      Jiri Pirko authored
      84c49d8c ("veth: remove unneeded
      ifname code from veth_newlink()") caused regression on veth
      creation. This patch reverts the original one.
      Reported-by: default avatarMichał Mirosław <mirqus@gmail.com>
      Signed-off-by: default avatarJiri Pirko <jpirko@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6c8c4446
    • Rabin Vincent's avatar
      smsc95xx: fix reset check · d9460920
      Rabin Vincent authored
      The reset loop check should check the MII_BMCR register value for
      BMCR_RESET rather than for MII_BMCR (the register address, which also
      happens to be zero).
      Signed-off-by: default avatarRabin Vincent <rabin@rab.in>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d9460920
    • Rafael J. Wysocki's avatar
      tg3: Fix failure to enable WoL by default when possible · 6fdbab9d
      Rafael J. Wysocki authored
      tg3 is supposed to enable WoL by default on adapters which support
      that, but it fails to do so unless the adapter's
      /sys/devices/.../power/wakeup file contains 'enabled' during the
      initialization of the adapter.  Fix that by making tg3 use
      device_set_wakeup_enable() to enable wakeup automatically whenever
      WoL should be enabled by default.
      Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6fdbab9d
    • Lifeng Sun's avatar
      networking: inappropriate ioctl operation should return ENOTTY · 41c31f31
      Lifeng Sun authored
      ioctl() calls against a socket with an inappropriate ioctl operation
      are incorrectly returning EINVAL rather than ENOTTY:
      
        [ENOTTY]
            Inappropriate I/O control operation.
      
      BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=33992Signed-off-by: default avatarLifeng Sun <lifongsun@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      41c31f31
    • H. Peter Anvin's avatar
      x86, reboot: Fix relocations in reboot_32.S · 7806a49a
      H. Peter Anvin authored
      The use of base for %ebx in this file is arbitrary, *except* that we
      also use it to compute the real-mode segment.  Therefore, make it so
      that r_base really is the true address to which %ebx points.
      
      This resolves kernel bugzilla 33302.
      Reported-and-tested-by: default avatarAlexey Zaytsev <alexey.zaytsev@gmail.com>
      Signed-off-by: default avatarH. Peter Anvin <hpa@zytor.com>
      Link: http://lkml.kernel.org/n/tip-08os5wi3yq1no0y4i5m4z7he@git.kernel.org
      7806a49a
    • Joe Perches's avatar
    • B.J. Buchalter's avatar
      firewire: Fix for broken configrom updates in quick succession · 2e053a27
      B.J. Buchalter authored
      Current implementation of ohci_set_config_rom() uses a deferred
      bus reset via fw_schedule_bus_reset(). If clients add multiple
      unit descriptors to the config_rom in quick succession, the
      deferred bus reset may not have fired before succeeding update
      requests have come in. This can lead to an incorrect partial
      update of the config_rom for both addition and removal of
      config_rom descriptors, as the ohci_set_config_rom() routine
      will return -EBUSY if a previous pending update has not been
      completed yet; the requested update just gets dropped on the floor.
      
      This patch recognizes that the "in-flight" update can be modified
      until it has been processed by the bus-reset, and the locking
      in the bus_reset_tasklet ensures that the update is done atomically
      with respect to modifications made by ohci_set_config_rom(). The
      -EBUSY error case is simply removed.
      
      [Stefan R:  The bug always existed at least theoretically.  But it
      became easy to trigger since 2.6.36 commit 02d37bed "firewire: core:
      integrate software-forced bus resets with bus management" which
      introduced long mandatory delays between janitorial bus resets.]
      Signed-off-by: default avatarBenjamin Buchalter <bj@mhlabs.com>
      Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de> (trivial style changes)
      Cc: <stable@kernel.org> # 2.6.36.y and newer
      2e053a27
    • Stefano Stabellini's avatar
      xen: mask_rw_pte mark RO all pagetable pages up to pgt_buf_top · b9269dc7
      Stefano Stabellini authored
      mask_rw_pte is currently checking if a pfn is a pagetable page if it
      falls in the range pgt_buf_start - pgt_buf_end but that is incorrect
      because pgt_buf_end is a moving target: pgt_buf_top is the real
      boundary.
      Acked-by: default avatar"H. Peter Anvin" <hpa@zytor.com>
      Signed-off-by: default avatarStefano Stabellini <stefano.stabellini@eu.citrix.com>
      Signed-off-by: default avatarKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      b9269dc7
    • Konrad Rzeszutek Wilk's avatar
      xen/mmu: Add workaround "x86-64, mm: Put early page table high" · a3864783
      Konrad Rzeszutek Wilk authored
      As a consequence of the commit:
      
      commit 4b239f45
      Author: Yinghai Lu <yinghai@kernel.org>
      Date:   Fri Dec 17 16:58:28 2010 -0800
      
          x86-64, mm: Put early page table high
      
      it causes the Linux kernel to crash under Xen:
      
      mapping kernel into physical memory
      Xen: setup ISA identity maps
      about to get started...
      (XEN) mm.c:2466:d0 Bad type (saw 7400000000000001 != exp 1000000000000000) for mfn b1d89 (pfn bacf7)
      (XEN) mm.c:3027:d0 Error while pinning mfn b1d89
      (XEN) traps.c:481:d0 Unhandled invalid opcode fault/trap [#6] on VCPU 0 [ec=0000]
      (XEN) domain_crash_sync called from entry.S
      (XEN) Domain 0 (vcpu#0) crashed on cpu#0:
      ...
      
      The reason is that at some point init_memory_mapping is going to reach
      the pagetable pages area and map those pages too (mapping them as normal
      memory that falls in the range of addresses passed to init_memory_mapping
      as argument). Some of those pages are already pagetable pages (they are
      in the range pgt_buf_start-pgt_buf_end) therefore they are going to be
      mapped RO and everything is fine.
      Some of these pages are not pagetable pages yet (they fall in the range
      pgt_buf_end-pgt_buf_top; for example the page at pgt_buf_end) so they
      are going to be mapped RW.  When these pages become pagetable pages and
      are hooked into the pagetable, xen will find that the guest has already
      a RW mapping of them somewhere and fail the operation.
      The reason Xen requires pagetables to be RO is that the hypervisor needs
      to verify that the pagetables are valid before using them. The validation
      operations are called "pinning" (more details in arch/x86/xen/mmu.c).
      
      In order to fix the issue we mark all the pages in the entire range
      pgt_buf_start-pgt_buf_top as RO, however when the pagetable allocation
      is completed only the range pgt_buf_start-pgt_buf_end is reserved by
      init_memory_mapping. Hence the kernel is going to crash as soon as one
      of the pages in the range pgt_buf_end-pgt_buf_top is reused (b/c those
      ranges are RO).
      
      For this reason, this function is introduced which is called _after_
      the init_memory_mapping has completed (in a perfect world we would
      call this function from init_memory_mapping, but lets ignore that).
      
      Because we are called _after_ init_memory_mapping the pgt_buf_[start,
      end,top] have all changed to new values (b/c another init_memory_mapping
      is called). Hence, the first time we enter this function, we save
      away the pgt_buf_start value and update the pgt_buf_[end,top].
      
      When we detect that the "old" pgt_buf_start through pgt_buf_end
      PFNs have been reserved (so memblock_x86_reserve_range has been called),
      we immediately set out to RW the "old" pgt_buf_end through pgt_buf_top.
      
      And then we update those "old" pgt_buf_[end|top] with the new ones
      so that we can redo this on the next pagetable.
      Acked-by: default avatar"H. Peter Anvin" <hpa@zytor.com>
      Reviewed-by: default avatarJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
      [v1: Updated with Jeremy's comments]
      [v2: Added the crash output]
      Signed-off-by: default avatarKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      a3864783
    • David S. Miller's avatar
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.infradead.org/ubifs-2.6 · adadfe48
      Linus Torvalds authored
      * 'for-linus' of git://git.infradead.org/ubifs-2.6:
        UBIFS: seek journal heads to the latest bud in replay
        UBIFS: do not free write-buffers when in R/O mode
      adadfe48
    • Linus Torvalds's avatar
      Merge branch 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm · 625a3b60
      Linus Torvalds authored
      * 'fixes' of master.kernel.org:/home/rmk/linux-2.6-arm: (47 commits)
        CLKDEV: Fix clkdev return value for NULL clk case
        ARM: 6891/1: prevent heap corruption in OABI semtimedop
        ARM: kprobes: Tidy-up kprobes-decode.c
        ARM: kprobes: Add emulation of hint instructions like NOP and WFI
        ARM: kprobes: Add emulation of SBFX, UBFX, BFI and BFC instructions
        ARM: kprobes: Add emulation of MOVW and MOVT instructions
        ARM: kprobes: Reject probing of undefined data processing instructions
        ARM: kprobes: Remove redundant code in space_1111
        ARM: kprobes: Fix emulation of PLD instructions
        ARM: kprobes: Reject probing of SETEND instructions
        ARM: kprobes: Consolidate stub decoding functions
        ARM: kprobes: Reject probing of all coprocessor instructions
        ARM: kprobes: Fix emulation of USAD8 instructions
        ARM: kprobes: Fix emulation of SMUAD, SMUSD and SMMUL instructions
        ARM: kprobes: Fix emulation of SXTB16, SXTB, SXTH, UXTB16, UXTB and UXTH instructions
        ARM: kprobes: Reject probing of undefined media instructions
        ARM: kprobes: Add emulation of RBIT instruction
        ARM: kprobes: Reject probing of LDRB instructions which load PC
        ARM: kprobes: Fix emulation of LDRD and STRD instructions
        ARM: kprobes: Reject probing of LDR/STR instructions which update PC unpredictably
        ...
      625a3b60