1. 05 12月, 2016 3 次提交
  2. 30 10月, 2016 2 次提交
  3. 13 10月, 2016 1 次提交
    • J
      net: deprecate eth_change_mtu, remove usage · a52ad514
      Jarod Wilson 提交于
      With centralized MTU checking, there's nothing productive done by
      eth_change_mtu that isn't already done in dev_set_mtu, so mark it as
      deprecated and remove all usage of it in the kernel. All callers have been
      audited for calls to alloc_etherdev* or ether_setup directly, which means
      they all have a valid dev->min_mtu and dev->max_mtu. Now eth_change_mtu
      prints out a netdev_warn about being deprecated, for the benefit of
      out-of-tree drivers that might be utilizing it.
      
      Of note, dvb_net.c actually had dev->mtu = 4096, while using
      eth_change_mtu, meaning that if you ever tried changing it's mtu, you
      couldn't set it above 1500 anymore. It's now getting dev->max_mtu also set
      to 4096 to remedy that.
      
      v2: fix up lantiq_etop, missed breakage due to drive not compiling on x86
      
      CC: netdev@vger.kernel.org
      Signed-off-by: NJarod Wilson <jarod@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a52ad514
  4. 08 10月, 2016 1 次提交
  5. 30 9月, 2016 1 次提交
  6. 28 9月, 2016 1 次提交
  7. 26 9月, 2016 15 次提交
    • M
      m68k: let clk_disable() return immediately if clk is NULL · 742859ad
      Masahiro Yamada 提交于
      In many of clk_disable() implementations, it is a no-op for a NULL
      pointer input, but this is one of the exceptions.
      
      Making it treewide consistent will allow clock consumers to call
      clk_disable() without NULL pointer check.
      Signed-off-by: NMasahiro Yamada <yamada.masahiro@socionext.com>
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      742859ad
    • G
      m68knommu: convert printk(KERN_INFO) to pr_info() · 3ec53d6f
      Greg Ungerer 提交于
      The old style use of printk(KERN_INFO) is depracated. Convert use of it
      in setup_no.c to the modern pr_info().
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      3ec53d6f
    • G
      m68knommu: clean up uClinux boot log output · 150cefbb
      Greg Ungerer 提交于
      During the arch setup phase of kernel boot we print out in the boot banner
      that we are uClinux configured. The printk currently contains a bunch of
      useless newlines and carriage returns - producing wastefull empty lines.
      Remove these.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      150cefbb
    • G
      m68k: generalize uboot command line support · aa5ac789
      Greg Ungerer 提交于
      The uboot command line support needs to be used by both MMU and no-MMU
      setups, but currently we only have the code in the no-MMU code paths.
      Move the uboot command line processing code into its own file. Add
      appropriate calls to it from both the MMU and no-MMU arch setup code.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      Acked-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      aa5ac789
    • G
      m68k: don't panic if no hardware FPU defined · 2a744007
      Greg Ungerer 提交于
      If we boot up and find no hardware FPU we panic and die.
      
      Change this behavior to be that if we boot up and we _expect_ a hardware
      FPU to be present then panic. Don't panic if we don't actually expect to
      have any hardware FPU.
      
      This lets us compile a kernel without FPU if we really choose too.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      2a744007
    • G
      m68k: only generate FPU instructions if CONFIG_FPU enabled · 6d3ec805
      Greg Ungerer 提交于
      Most of the m68k code that supports a hardware FPU is surrounded by
      CONFIG_FPU. Be consistent and surround the hardware FPU instruction
      setup in setup_mm.c with CONFIG_FPU as well as the check for
      CONFIG_M68KFPU_EMU_ONLY.
      
      The existing classic m68k architectures all define CONFIG_FPU, so they
      see no change from this. But on ColdFire where we do not support the
      emulated FP code we can now compile without CONFIG_FPU being set as well.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      6d3ec805
    • G
      m68k: always make available dump_fpu() · 8912eacc
      Greg Ungerer 提交于
      Our local m68k architecture dump_fpu() is conditionally compiled in on
      CONFIG_FPU. That is OK for all existing MMU enabled CPU types, but won't
      handle the case for some ColdFire SoC CPU parts that we want to support
      that have no FPU hardware.
      
      dump_fpu() is expected to be present by the ELF loader, so we must always
      have it available and exported.
      
      Remove the conditional and reorganize the dump_fpu hard FPU code path
      to let the compiler remove code when not needed.
      
      This change based on changes and discussion from Yannick Gicquel
      <yannick.gicquel@open.eurogiciel.org>.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      8912eacc
    • G
      m68k: generalize io memory region setup for ColdFire ACR registers · 8cf4a973
      Greg Ungerer 提交于
      The ACR registers of the ColdFire define at a macro level what regions
      of the addresses space should have caching or other attribute types applied.
      
      Currently for the MMU enabled setups we map the interal IO peripheral addres
      space as uncachable based on the define for the MBAR address (CONFIG_MBAR).
      Not all ColdFire SoC use a programmable MBAR register address. Some parts
      have fixed addressing for their internal peripheral registers.
      
      Generalize the way we get the internal peripheral base address so all types
      can be accomodated in the ACR definitions. Each ColdFire SoC type now sets
      its IO memory base and size definitions (which may be based on MBAR) which
      are then used in the ACR definitions.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      8cf4a973
    • G
      m68k: move ColdFire _bootmem_alloc code · f7116065
      Greg Ungerer 提交于
      The early ColdFire bootmem_alloc() code is currently only included in
      the board support for the Coldire 54xx platforms. It will be used on all
      ColdFire MMU enabled platforms as others are supported. So move the
      mcf54xx_bootmem_alloc() function to be generally available to all MMU
      enabled ColdFire parts (and use a more generic name for it).
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      f7116065
    • G
      m68k: report correct FPU type on ColdFire MMU platforms · cbd5b982
      Greg Ungerer 提交于
      Not all ColdFire SoC parts that have an MMU also have an FPU - so set
      an FPU type (via m68k_fputype) appropriate for the configured platform.
      
      With this set correctly /proc/cpuinfo will report FPU "none" on devices
      that don't have one. And kernel code paths that initialize FPU hardware
      will now only execute if an FPU is actually present.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      cbd5b982
    • G
      m68k: set appropriate machine type for m5411x SoC platforms · 81d33350
      Greg Ungerer 提交于
      Create a new machine type for platforms based around the ColdFire 5441x
      SoC family. Set that machine type on startup when building for this
      platform type.
      
      Currently the ColdFire head.S hard codes a M54xx machine type at startup -
      since that is the only platform type currently supported with MMU enabled.
      The m5441x has an MMU and this change forms part of the support required
      to run it with the MMU enabled.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      81d33350
    • G
      m68k: move CONFIG_FPU set to per-CPU configuration · e5f8d1f0
      Greg Ungerer 提交于
      Move the selection of CONFIG_FPU to each CPU type configuration.
      
      Currently for m68k we have a global set of CONFIG_FPU based on if CONFIG_MMU
      is enabled or not. There is at least one CPU family we support (m5441x)
      that has an MMU but has no FPU hardware. So we need to be able to have
      CONFIG_MMU set and CONFIG_FPU not set.
      
      Whether we build for a CPU with MMU enabled or not doesn't change the
      fact that it has FPU hardware support. Our current non-MMU builds have
      never had CONIG_FPU enabled - and in fact the kernel will not compile
      with that set and CONFIG_MMU not set at the moment. It is easy enough
      to fix this - but it would involve a structure change to sigcontext.h,
      and that is a user space exported header (so ABI change).
      
      This change makes no configuration visible changes, and all configs
      end up with the same configuration settings as before.
      
      This change based on changes and discussion from Yannick Gicquel
      <yannick.gicquel@open.eurogiciel.org>.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      e5f8d1f0
    • G
      m68knommu: fix IO write size in nettel pin set · 36d050d9
      Greg Ungerer 提交于
      The pin write code that supports the UART signals is not using he correct
      word write IO access method. It correctly reads the correct 16 bit
      registrer, it should also write the new value back with a 16 bit write.
      Fix it to use writew().
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      36d050d9
    • G
      m68knommu: switch to using IO access methods in WildFire board code · 41b39ea1
      Greg Ungerer 提交于
      Most ColdFire support code has switched to using IO memory access
      methods (readb/writeb/etc) when reading and writing internal peripheral
      device registers. The WildFire board specific halt code was missed.
      
      As it is now the WildFire code is broken, since all register definitions
      were changed to be register addresses only some time ago.
      
      Fix the WildFire board code to use the appropriate IO access functions.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      41b39ea1
    • G
      m68knommu: fix early setup to not access variables · bc065e47
      Greg Ungerer 提交于
      The early setup code for the ColdFire 53xx platform accesses variables
      before the RAM and other system initialization steps may have taken place.
      Currently it has 2 global variables that will end up in the bss section
      that are accessed during this early setup. There is a special static RAM
      stack setup at this time, but not necessarily the RAM where kernel data
      sections will end up.
      
      Even on system setups where RAM is setup by a boot loader the access
      to the early setup variables is before the BSS section has been initialized.
      This can potentially corrupt a ram loaded root filesystem that sits in that
      memory area before it has been moved.
      
      These 2 variables are not used at all after being set, and can just be
      removed.
      Reported-by: NChristian Gieseler <christiangieseler@yahoo.de>
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      bc065e47
  8. 19 9月, 2016 1 次提交
  9. 29 8月, 2016 1 次提交
  10. 08 8月, 2016 2 次提交
    • A
      m68k: move exports to definitions · d13ffb56
      Al Viro 提交于
      Acked-by: NGeert Uytterhoeven <geert@linux-m68k.org>
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      d13ffb56
    • G
      m68knommu: fix user a5 register being overwritten · 0b980271
      Greg Ungerer 提交于
      On no-MMU systems the application a5 register can be overwitten with the
      address of the process data segment when processing application signals.
      For flat format applications compiled with full absolute relocation this
      effectively corrupts the a5 register on signal processing - and this very
      quickly leads to process crash and often takes out the whole system with
      a panic as well.
      
      This has no effect on flat format applications compiled with the more
      common PIC methods (such as -msep-data). These format applications reserve
      a5 for the pointer to the data segment anyway - so it doesn't change it.
      
      A long time ago the a5 register was used in the code packed into the user
      stack to enable signal return processing. And so it had to be restored on
      end of signal cleanup processing back to the original a5 user value. This
      was historically done by saving away a5 in the sigcontext structure. At
      some point (a long time back it seems) the a5 restore process was changed
      and it was hard coded to put the user data segment address directly into a5.
      Which is ok for the common PIC compiled application case, but breaks the
      full relocation application code.
      
      We no longer use this type of signal handling mechanism and so we don't
      need to do anything special to save and restore a5 at all now. So remove the
      code that hard codes a5 to the address of the user data segment.
      Signed-off-by: NGreg Ungerer <gerg@linux-m68k.org>
      0b980271
  11. 04 8月, 2016 1 次提交
    • K
      dma-mapping: use unsigned long for dma_attrs · 00085f1e
      Krzysztof Kozlowski 提交于
      The dma-mapping core and the implementations do not change the DMA
      attributes passed by pointer.  Thus the pointer can point to const data.
      However the attributes do not have to be a bitfield.  Instead unsigned
      long will do fine:
      
      1. This is just simpler.  Both in terms of reading the code and setting
         attributes.  Instead of initializing local attributes on the stack
         and passing pointer to it to dma_set_attr(), just set the bits.
      
      2. It brings safeness and checking for const correctness because the
         attributes are passed by value.
      
      Semantic patches for this change (at least most of them):
      
          virtual patch
          virtual context
      
          @r@
          identifier f, attrs;
      
          @@
          f(...,
          - struct dma_attrs *attrs
          + unsigned long attrs
          , ...)
          {
          ...
          }
      
          @@
          identifier r.f;
          @@
          f(...,
          - NULL
          + 0
           )
      
      and
      
          // Options: --all-includes
          virtual patch
          virtual context
      
          @r@
          identifier f, attrs;
          type t;
      
          @@
          t f(..., struct dma_attrs *attrs);
      
          @@
          identifier r.f;
          @@
          f(...,
          - NULL
          + 0
           )
      
      Link: http://lkml.kernel.org/r/1468399300-5399-2-git-send-email-k.kozlowski@samsung.comSigned-off-by: NKrzysztof Kozlowski <k.kozlowski@samsung.com>
      Acked-by: NVineet Gupta <vgupta@synopsys.com>
      Acked-by: NRobin Murphy <robin.murphy@arm.com>
      Acked-by: NHans-Christian Noren Egtvedt <egtvedt@samfundet.no>
      Acked-by: Mark Salter <msalter@redhat.com> [c6x]
      Acked-by: Jesper Nilsson <jesper.nilsson@axis.com> [cris]
      Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch> [drm]
      Reviewed-by: NBart Van Assche <bart.vanassche@sandisk.com>
      Acked-by: Joerg Roedel <jroedel@suse.de> [iommu]
      Acked-by: Fabien Dessenne <fabien.dessenne@st.com> [bdisp]
      Reviewed-by: Marek Szyprowski <m.szyprowski@samsung.com> [vb2-core]
      Acked-by: David Vrabel <david.vrabel@citrix.com> [xen]
      Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> [xen swiotlb]
      Acked-by: Joerg Roedel <jroedel@suse.de> [iommu]
      Acked-by: Richard Kuo <rkuo@codeaurora.org> [hexagon]
      Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> [m68k]
      Acked-by: Gerald Schaefer <gerald.schaefer@de.ibm.com> [s390]
      Acked-by: NBjorn Andersson <bjorn.andersson@linaro.org>
      Acked-by: Hans-Christian Noren Egtvedt <egtvedt@samfundet.no> [avr32]
      Acked-by: Vineet Gupta <vgupta@synopsys.com> [arc]
      Acked-by: Robin Murphy <robin.murphy@arm.com> [arm64 and dma-iommu]
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      00085f1e
  12. 28 7月, 2016 1 次提交
  13. 27 7月, 2016 1 次提交
  14. 25 7月, 2016 3 次提交
  15. 19 7月, 2016 1 次提交
  16. 03 7月, 2016 1 次提交
  17. 25 6月, 2016 1 次提交
    • M
      tree wide: get rid of __GFP_REPEAT for order-0 allocations part I · 32d6bd90
      Michal Hocko 提交于
      This is the third version of the patchset previously sent [1].  I have
      basically only rebased it on top of 4.7-rc1 tree and dropped "dm: get
      rid of superfluous gfp flags" which went through dm tree.  I am sending
      it now because it is tree wide and chances for conflicts are reduced
      considerably when we want to target rc2.  I plan to send the next step
      and rename the flag and move to a better semantic later during this
      release cycle so we will have a new semantic ready for 4.8 merge window
      hopefully.
      
      Motivation:
      
      While working on something unrelated I've checked the current usage of
      __GFP_REPEAT in the tree.  It seems that a majority of the usage is and
      always has been bogus because __GFP_REPEAT has always been about costly
      high order allocations while we are using it for order-0 or very small
      orders very often.  It seems that a big pile of them is just a
      copy&paste when a code has been adopted from one arch to another.
      
      I think it makes some sense to get rid of them because they are just
      making the semantic more unclear.  Please note that GFP_REPEAT is
      documented as
      
      * __GFP_REPEAT: Try hard to allocate the memory, but the allocation attempt
      
      * _might_ fail.  This depends upon the particular VM implementation.
        while !costly requests have basically nofail semantic.  So one could
        reasonably expect that order-0 request with __GFP_REPEAT will not loop
        for ever.  This is not implemented right now though.
      
      I would like to move on with __GFP_REPEAT and define a better semantic
      for it.
      
        $ git grep __GFP_REPEAT origin/master | wc -l
        111
        $ git grep __GFP_REPEAT | wc -l
        36
      
      So we are down to the third after this patch series.  The remaining
      places really seem to be relying on __GFP_REPEAT due to large allocation
      requests.  This still needs some double checking which I will do later
      after all the simple ones are sorted out.
      
      I am touching a lot of arch specific code here and I hope I got it right
      but as a matter of fact I even didn't compile test for some archs as I
      do not have cross compiler for them.  Patches should be quite trivial to
      review for stupid compile mistakes though.  The tricky parts are usually
      hidden by macro definitions and thats where I would appreciate help from
      arch maintainers.
      
      [1] http://lkml.kernel.org/r/1461849846-27209-1-git-send-email-mhocko@kernel.org
      
      This patch (of 19):
      
      __GFP_REPEAT has a rather weak semantic but since it has been introduced
      around 2.6.12 it has been ignored for low order allocations.  Yet we
      have the full kernel tree with its usage for apparently order-0
      allocations.  This is really confusing because __GFP_REPEAT is
      explicitly documented to allow allocation failures which is a weaker
      semantic than the current order-0 has (basically nofail).
      
      Let's simply drop __GFP_REPEAT from those places.  This would allow to
      identify place which really need allocator to retry harder and formulate
      a more specific semantic for what the flag is supposed to do actually.
      
      Link: http://lkml.kernel.org/r/1464599699-30131-2-git-send-email-mhocko@kernel.orgSigned-off-by: NMichal Hocko <mhocko@suse.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: "H. Peter Anvin" <hpa@zytor.com>
      Cc: "James E.J. Bottomley" <jejb@parisc-linux.org>
      Cc: "Theodore Ts'o" <tytso@mit.edu>
      Cc: Andy Lutomirski <luto@kernel.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Catalin Marinas <catalin.marinas@arm.com>
      Cc: Chen Liqin <liqin.linux@gmail.com>
      Cc: Chris Metcalf <cmetcalf@mellanox.com> [for tile]
      Cc: Guan Xuetao <gxt@mprc.pku.edu.cn>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Helge Deller <deller@gmx.de>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Jan Kara <jack@suse.cz>
      Cc: John Crispin <blogic@openwrt.org>
      Cc: Lennox Wu <lennox.wu@gmail.com>
      Cc: Ley Foon Tan <lftan@altera.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Matt Fleming <matt@codeblueprint.co.uk>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Rich Felker <dalias@libc.org>
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Vineet Gupta <vgupta@synopsys.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      32d6bd90
  18. 20 6月, 2016 1 次提交
  19. 16 6月, 2016 2 次提交
    • P
      locking/atomic: Remove linux/atomic.h:atomic_fetch_or() · b53d6bed
      Peter Zijlstra 提交于
      Since all architectures have this implemented now natively, remove this
      dead code.
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: linux-arch@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Signed-off-by: NIngo Molnar <mingo@kernel.org>
      b53d6bed
    • P
      locking/atomic, arch/m68k: Implement atomic_fetch_{add,sub,and,or,xor}() · e39d88ea
      Peter Zijlstra 提交于
      Implement FETCH-OP atomic primitives, these are very similar to the
      existing OP-RETURN primitives we already have, except they return the
      value of the atomic variable _before_ modification.
      
      This is especially useful for irreversible operations -- such as
      bitops (because it becomes impossible to reconstruct the state prior
      to modification).
      Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: linux-arch@vger.kernel.org
      Cc: linux-kernel@vger.kernel.org
      Cc: linux-m68k@lists.linux-m68k.org
      Signed-off-by: NIngo Molnar <mingo@kernel.org>
      e39d88ea