1. 30 5月, 2013 1 次提交
    • D
      MN10300: Need pci_iomap() and __pci_ioport_map() defining · 1aeeac7a
      David Howells 提交于
      Include the generic definitions of pci_iomap() and __pci_ioport_map()
      otherwise we can get errors like:
      
        lib/pci_iomap.c: In function 'pci_iomap':
        lib/pci_iomap.c:37: error: implicit declaration of function '__pci_ioport_map'
        lib/pci_iomap.c:37: warning: return makes pointer from integer without a cast
      
      and:
      
        drivers/pci/quirks.c: In function 'disable_igfx_irq':
        drivers/pci/quirks.c:2893: error: implicit declaration of function 'pci_iomap'
        drivers/pci/quirks.c:2893: warning: initialization makes pointer from integer without a cast
        drivers/pci/quirks.c: In function 'reset_ivb_igd':
        drivers/pci/quirks.c:3133: warning: assignment makes pointer from integer without a cast
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Acked-by: NKen Cox <jkc@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      1aeeac7a
  2. 08 4月, 2013 1 次提交
  3. 01 4月, 2013 1 次提交
    • K
      net: add option to enable error queue packets waking select · 7d4c04fc
      Keller, Jacob E 提交于
      Currently, when a socket receives something on the error queue it only wakes up
      the socket on select if it is in the "read" list, that is the socket has
      something to read. It is useful also to wake the socket if it is in the error
      list, which would enable software to wait on error queue packets without waking
      up for regular data on the socket. The main use case is for receiving
      timestamped transmit packets which return the timestamp to the socket via the
      error queue. This enables an application to select on the socket for the error
      queue only instead of for the regular traffic.
      
      -v2-
      * Added the SO_SELECT_ERR_QUEUE socket option to every architechture specific file
      * Modified every socket poll function that checks error queue
      Signed-off-by: NJacob Keller <jacob.e.keller@intel.com>
      Cc: Jeffrey Kirsher <jeffrey.t.kirsher@intel.com>
      Cc: Richard Cochran <richardcochran@gmail.com>
      Cc: Matthew Vick <matthew.vick@intel.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7d4c04fc
  4. 04 3月, 2013 1 次提交
  5. 26 2月, 2013 1 次提交
  6. 14 2月, 2013 1 次提交
    • A
      burying unused conditionals · d64008a8
      Al Viro 提交于
      __ARCH_WANT_SYS_RT_SIGACTION,
      __ARCH_WANT_SYS_RT_SIGSUSPEND,
      __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND,
      __ARCH_WANT_COMPAT_SYS_SCHED_RR_GET_INTERVAL - not used anymore
      CONFIG_GENERIC_{SIGALTSTACK,COMPAT_RT_SIG{ACTION,QUEUEINFO,PENDING,PROCMASK}} -
      can be assumed always set.
      d64008a8
  7. 04 2月, 2013 3 次提交
  8. 29 1月, 2013 1 次提交
    • G
      mn10300: Provide dummy dma_mmap_coherent() and dma_get_sgtable() · 90582b2a
      Geert Uytterhoeven 提交于
      mn10300/allmodconfig:
      
      drivers/media/v4l2-core/videobuf2-dma-contig.c: In function ‘vb2_dc_mmap’:
      drivers/media/v4l2-core/videobuf2-dma-contig.c:204: error: implicit declaration of function ‘dma_mmap_coherent’
      drivers/media/v4l2-core/videobuf2-dma-contig.c: In function ‘vb2_dc_get_base_sgt’:
      drivers/media/v4l2-core/videobuf2-dma-contig.c:387: error: implicit declaration of function ‘dma_get_sgtable’
      
      For architectures using dma_map_ops, dma_mmap_coherent() and
      dma_get_sgtable() are provided in <asm-generic/dma-mapping-common.h>.
      
      Mn10300 does not use dma_map_ops, hence it should implement them itself.
      For now, use dummy implementations that just return -EINVAL, until the API
      has been finalized.
      Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      Cc: Marek Szyprowski <m.szyprowski@samsung.com>
      Cc: linux-am33-list@redhat.com
      Signed-off-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      90582b2a
  9. 24 1月, 2013 1 次提交
  10. 17 1月, 2013 1 次提交
    • V
      sk-filter: Add ability to lock a socket filter program · d59577b6
      Vincent Bernat 提交于
      While a privileged program can open a raw socket, attach some
      restrictive filter and drop its privileges (or send the socket to an
      unprivileged program through some Unix socket), the filter can still
      be removed or modified by the unprivileged program. This commit adds a
      socket option to lock the filter (SO_LOCK_FILTER) preventing any
      modification of a socket filter program.
      
      This is similar to OpenBSD BIOCLOCK ioctl on bpf sockets, except even
      root is not allowed change/drop the filter.
      
      The state of the lock can be read with getsockopt(). No error is
      triggered if the state is not changed. -EPERM is returned when a user
      tries to remove the lock or to change/remove the filter while the lock
      is active. The check is done directly in sk_attach_filter() and
      sk_detach_filter() and does not affect only setsockopt() syscall.
      Signed-off-by: NVincent Bernat <bernat@luffy.cx>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d59577b6
  11. 20 12月, 2012 2 次提交
  12. 12 12月, 2012 2 次提交
  13. 29 11月, 2012 2 次提交
  14. 14 11月, 2012 1 次提交
  15. 01 11月, 2012 1 次提交
    • P
      sk-filter: Add ability to get socket filter program (v2) · a8fc9277
      Pavel Emelyanov 提交于
      The SO_ATTACH_FILTER option is set only. I propose to add the get
      ability by using SO_ATTACH_FILTER in getsockopt. To be less
      irritating to eyes the SO_GET_FILTER alias to it is declared. This
      ability is required by checkpoint-restore project to be able to
      save full state of a socket.
      
      There are two issues with getting filter back.
      
      First, kernel modifies the sock_filter->code on filter load, thus in
      order to return the filter element back to user we have to decode it
      into user-visible constants. Fortunately the modification in question
      is interconvertible.
      
      Second, the BPF_S_ALU_DIV_K code modifies the command argument k to
      speed up the run-time division by doing kernel_k = reciprocal(user_k).
      Bad news is that different user_k may result in same kernel_k, so we
      can't get the original user_k back. Good news is that we don't have
      to do it. What we need to is calculate a user2_k so, that
      
        reciprocal(user2_k) == reciprocal(user_k) == kernel_k
      
      i.e. if it's re-loaded back the compiled again value will be exactly
      the same as it was. That said, the user2_k can be calculated like this
      
        user2_k = reciprocal(kernel_k)
      
      with an exception, that if kernel_k == 0, then user2_k == 1.
      
      The optlen argument is treated like this -- when zero, kernel returns
      the amount of sock_fprog elements in filter, otherwise it should be
      large enough for the sock_fprog array.
      
      changes since v1:
      * Declared SO_GET_FILTER in all arch headers
      * Added decode of vlan-tag codes
      Signed-off-by: NPavel Emelyanov <xemul@parallels.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a8fc9277
  16. 17 10月, 2012 1 次提交
  17. 15 10月, 2012 1 次提交
  18. 10 10月, 2012 1 次提交
  19. 06 10月, 2012 1 次提交
    • J
      cross-arch: don't corrupt personality flags upon exec() · 16f3e95b
      Jiri Kosina 提交于
      Historically, the top three bytes of personality have been used for
      things such as ADDR_NO_RANDOMIZE, which made sense only for specific
      architectures.
      
      We now however have a flag there that is general no matter the
      architecture (UNAME26); generally we have to be careful to preserve the
      personality flags across exec().
      
      This patch tries to fix all architectures that forcefully overwrite
      personality flags during exec() (ppc32 and s390 have been fixed recently
      by commits f9783ec8 ("[S390] Do not clobber personality flags on
      exec") and 59e4c3a2 ("powerpc/32: Don't clobber personality flags on
      exec") in a similar way already).
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Hans-Christian Egtvedt <egtvedt@samfundet.no>
      Cc: Mike Frysinger <vapier@gentoo.org>
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Richard Kuo <rkuo@codeaurora.org>
      Cc: Hirokazu Takata <takata@linux-m32r.org>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: Chen Liqin <liqin.chen@sunplusct.com>
      Cc: Lennox Wu <lennox.wu@gmail.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Chris Zankel <chris@zankel.net>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      16f3e95b
  20. 04 10月, 2012 1 次提交
  21. 03 10月, 2012 1 次提交
  22. 01 10月, 2012 5 次提交
  23. 28 9月, 2012 1 次提交
    • D
      Make most arch asm/module.h files use asm-generic/module.h · 786d35d4
      David Howells 提交于
      Use the mapping of Elf_[SPE]hdr, Elf_Addr, Elf_Sym, Elf_Dyn, Elf_Rel/Rela,
      ELF_R_TYPE() and ELF_R_SYM() to either the 32-bit version or the 64-bit version
      into asm-generic/module.h for all arches bar MIPS.
      
      Also, use the generic definition mod_arch_specific where possible.
      
      To this end, I've defined three new config bools:
      
       (*) HAVE_MOD_ARCH_SPECIFIC
      
           Arches define this if they don't want to use the empty generic
           mod_arch_specific struct.
      
       (*) MODULES_USE_ELF_RELA
      
           Arches define this if their modules can contain RELA records.  This causes
           the Elf_Rela mapping to be emitted and allows apply_relocate_add() to be
           defined by the arch rather than have the core emit an error message.
      
       (*) MODULES_USE_ELF_REL
      
           Arches define this if their modules can contain REL records.  This causes
           the Elf_Rel mapping to be emitted and allows apply_relocate() to be
           defined by the arch rather than have the core emit an error message.
      
      Note that it is possible to allow both REL and RELA records: m68k and mips are
      two arches that do this.
      
      With this, some arch asm/module.h files can be deleted entirely and replaced
      with a generic-y marker in the arch Kbuild file.
      
      Additionally, I have removed the bits from m32r and score that handle the
      unsupported type of relocation record as that's now handled centrally.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Acked-by: NSam Ravnborg <sam@ravnborg.org>
      Signed-off-by: NRusty Russell <rusty@rustcorp.com.au>
      786d35d4
  24. 20 9月, 2012 1 次提交
  25. 31 7月, 2012 1 次提交
  26. 12 7月, 2012 3 次提交
    • G
      mn10300: remove duplicate definition of PTRACE_O_TRACESYSGOOD · 1c20c3de
      Geert Uytterhoeven 提交于
      Fix the warning:
      
        include/linux/ptrace.h:66:0: warning: "PTRACE_O_TRACESYSGOOD" redefined [enabled by default]
        arch/mn10300/include/asm/ptrace.h:85:0: note: this is the location of the previous definition
      
      We already have it in <linux/ptrace.h>, so remove it from <asm/ptrace.h>
      Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      1c20c3de
    • G
      mn10300: move setup_jiffies_interrupt() to cevt-mn10300.c · 325c1170
      Geert Uytterhoeven 提交于
      Move the static inline function setup_jiffies_interrupt() from
      <asm/timex.h> to arch/mn10300/kernel/cevt-mn10300.c, which is its only
      callsite.
      
      This allows to remove the inclusion of <asm/hardirq.h> and <linux/irq.h>
      from <asm/timex.h> and <unit/timex.h>, fixing include hell like:
      
        include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
        include/linux/jiffies.h:260:31: warning: "CLOCK_TICK_RATE" is not defined [-Wundef]
        include/linux/jiffies.h:46:42: error: division by zero in #if
        ...
        make[4]: *** [arch/mn10300/kernel/asm-offsets.s] Error 1
      
      and (after a quick hack for the above by defining CLOCK_TICK_RATE in
      <linux/jiffies.h>):
      
        In file included from include/linux/notifier.h:15:0,
                       from include/linux/memory_hotplug.h:6,
                       from include/linux/mmzone.h:718,
                       from include/linux/gfp.h:4,
                       from include/linux/irq.h:20,
                       from arch/mn10300/unit-asb2303/include/unit/timex.h:15,
                       from arch/mn10300/include/asm/timex.h:15,
                       from include/linux/timex.h:174,
                       from include/linux/jiffies.h:8,
                       from include/linux/ktime.h:25,
                       from include/linux/timer.h:5,
                       from include/linux/workqueue.h:8,
        include/linux/srcu.h:55:22: error: field 'work' has incomplete type
      
      As a consequence, we do need a few more inclusions of <asm/irq.h>, namely
      in arch/mn10300/unit-asb2303/smc91111.c and
      arch/mn10300/unit-asb2305/unit-init.c.
      Signed-off-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      325c1170
    • D
      MN10300: Fix a missing semicolon · 43224b73
      David Howells 提交于
      The declaration of arch_release_thread_info() needs a semicolon.
      Signed-off-by: NDavid Howells <dhowells@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      43224b73
  27. 28 6月, 2012 1 次提交
  28. 31 5月, 2012 1 次提交
  29. 17 5月, 2012 1 次提交
    • S
      fork: move the real prepare_to_copy() users to arch_dup_task_struct() · 55ccf3fe
      Suresh Siddha 提交于
      Historical prepare_to_copy() is mostly a no-op, duplicated for majority of
      the architectures and the rest following the x86 model of flushing the extended
      register state like fpu there.
      
      Remove it and use the arch_dup_task_struct() instead.
      Suggested-by: NOleg Nesterov <oleg@redhat.com>
      Suggested-by: NLinus Torvalds <torvalds@linux-foundation.org>
      Signed-off-by: NSuresh Siddha <suresh.b.siddha@intel.com>
      Link: http://lkml.kernel.org/r/1336692811-30576-1-git-send-email-suresh.b.siddha@intel.comAcked-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Koichi Yasutake <yasutake.koichi@jp.panasonic.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Haavard Skinnemoen <hskinnemoen@gmail.com>
      Cc: Mike Frysinger <vapier@gentoo.org>
      Cc: Mark Salter <msalter@redhat.com>
      Cc: Aurelien Jacquiot <a-jacquiot@ti.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Richard Kuo <rkuo@codeaurora.org>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: Michal Simek <monstr@monstr.eu>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Jonas Bonn <jonas@southpole.se>
      Cc: James E.J. Bottomley <jejb@parisc-linux.org>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Chen Liqin <liqin.chen@sunplusct.com>
      Cc: Lennox Wu <lennox.wu@gmail.com>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Chris Metcalf <cmetcalf@tilera.com>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Richard Weinberger <richard@nod.at>
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Signed-off-by: NH. Peter Anvin <hpa@linux.intel.com>
      55ccf3fe