1. 12 Jul, 2012 8 commits
    • Rob Herring's avatar
      clk: add highbank clock support · 8d4d9f52
      Rob Herring authored
      This adds real clock support to Calxeda Highbank SOC using the common
      clock infrastructure.
      Signed-off-by: default avatarRob Herring <rob.herring@calxeda.com>
      [mturquette@linaro.org: fixed up invalid writes to const struct member]
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      8d4d9f52
    • Rob Herring's avatar
      dt: add clock binding doc to primecell bindings · 260b6aa0
      Rob Herring authored
      Add clock binding information for primecell peripherals. For most, a
      clock input name of "apb_pclk" is required. Any primecell peripherals
      which are different will need to be documented separately.
      Signed-off-by: default avatarRob Herring <rob.herring@calxeda.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      260b6aa0
    • Grant Likely's avatar
      clk: add DT fixed-clock binding support · 015ba402
      Grant Likely authored
      Add support for DT "fixed-clock" binding to the common fixed rate clock
      support.
      Signed-off-by: default avatarGrant Likely <grant.likely@secretlab.ca>
      [Rob Herring] Rework and move into common clock infrastructure
      Signed-off-by: default avatarRob Herring <rob.herring@calxeda.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      015ba402
    • Grant Likely's avatar
      clk: add DT clock binding support · 766e6a4e
      Grant Likely authored
      Based on work 1st by Ben Herrenschmidt and Jeremy Kerr, then by Grant
      Likely, this patch adds support to clk_get to allow drivers to retrieve
      clock data from the device tree.
      
      Platforms scan for clocks in DT with of_clk_init and a match table, and
      the register a provider through of_clk_add_provider. The provider's
      clk_src_get function will be called when a device references the
      provider's OF node for a clock reference.
      
      v6 (Rob Herring):
          - Return error values instead of NULL to match clock framework
            expectations
      
      v5 (Rob Herring):
          - Move from drivers/of into common clock subsystem
          - Squashed "dt/clock: add a simple provider get function" and
            "dt/clock: add function to get parent clock name"
          - Rebase to 3.4-rc1
          - Drop CONFIG_OF_CLOCK and just use CONFIG_OF
          - Add missing EXPORT_SYMBOL to various functions
          - s/clock-output-name/clock-output-names/
          - Define that fixed-clock binding is a single output
      
      v4 (Rob Herring):
          - Rework for common clk subsystem
          - Add of_clk_get_parent_name function
      
      v3: - Clarified documentation
      
      v2: - fixed errant ';' causing compile error
          - Editorial fixes from Shawn Guo
          - merged in adding lookup to clkdev
          - changed property names to match established convention. After
            working with the binding a bit it really made more sense to follow the
            lead of 'reg', 'gpios' and 'interrupts' by making the input simply
            'clocks' & 'clock-names' instead of 'clock-input-*', and to only use
            clock-output* for the producer nodes. (Sorry Shawn, this will mean
            you need to change some code, but it should be trivial)
          - Add ability to inherit clocks from parent nodes by using an empty
            'clock-ranges' property.  Useful for busses.  I could use some feedback
            on the new property name, 'clock-ranges' doesn't feel right to me.
      Signed-off-by: default avatarGrant Likely <grant.likely@secretlab.ca>
      Signed-off-by: default avatarRob Herring <rob.herring@calxeda.com>
      Reviewed-by: default avatarShawn Guo <shawn.guo@freescale.com>
      Cc: Sascha Hauer <kernel@pengutronix.de>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      766e6a4e
    • Linus Walleij's avatar
      ARM: integrator: convert to common clock · a613163d
      Linus Walleij authored
      This converts the Integrator platform to use common clock
      and the ICST driver. Since from this point not all ARM
      reference platforms use the clock, we define
      CONFIG_PLAT_VERSATILE_CLOCK and select it for all platforms
      except the Integrator.
      
      Open issue: I could not use the .init_early() field of the
      machine descriptor to initialize the clocks, but had to
      move them to .init_irq(), so presumably .init_early() is
      so early that common clock is not up, and .init_machine()
      is too late since it's needed for the clockevent/clocksource
      initialization. Any suggestions on how to solve this is
      very welcome.
      
      Cc: Russell King <linux@arm.linux.org.uk>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      [mturquette@linaro.org: use 'select' instead of versatile Kconfig]
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      a613163d
    • Linus Walleij's avatar
      clk: add versatile ICST307 driver · 91b87a47
      Linus Walleij authored
      The ICST307 VCO clock has a shared driver in the ARM
      architecture. This patch provides a wrapper into the common
      clock framework so we can use the implementation in the
      ARM architecture without duplicating the code until all
      ARM platforms using this VCO are moved over. At that point
      we can merge the driver from the ARM platform into the
      generic file altogether.
      
      Cc: Russell King <linux@arm.linux.org.uk>
      Cc: Mike Turquette <mturquette@ti.com>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      [mturquette@linaro.org: removed versatile Kconfig]
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      91b87a47
    • Linus Walleij's avatar
      ARM: integrator: put symbolic bus names on devices · d59fdcfc
      Linus Walleij authored
      All the Integrator devices have bus names like "mb:16" which
      I think means "memory base 0x16000000" which is where the
      UART0 is. So let's call it "uart0" because that's what most
      platforms do these days.
      
      Change this everywhere for the integrator as we prepare for
      some core clock code movement.
      
      Cc: Russell King <linux@arm.linux.org.uk>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      d59fdcfc
    • Mike Turquette's avatar
  2. 11 Jul, 2012 7 commits
    • Linus Walleij's avatar
      ARM: u300: convert to common clock · 50667d63
      Linus Walleij authored
      This converts the U300 clock implementation over to use the common
      struct clk and moves the implementation down into drivers/clk.
      Since VCO isn't used in tree it was removed, it's not hard to
      put it back in if need be.
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      [mturquette@linaro.org: trivial Makefile conflict]
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      50667d63
    • Rajendra Nayak's avatar
      clk: cache parent clocks only for muxes · 9ca1c5a4
      Rajendra Nayak authored
      caching parent clocks makes sense only when a clock has more
      than one parent (mux clocks).
      Avoid doing this for every other clock.
      Signed-off-by: default avatarRajendra Nayak <rnayak@ti.com>
      [mturquette@linaro.org: removed extra parentheses]
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      9ca1c5a4
    • Mark Brown's avatar
      clk: wm831x: Add initial WM831x clock driver · f05259a6
      Mark Brown authored
      The WM831x and WM832x series of PMICs contain a flexible clocking
      subsystem intended to provide always on and system core clocks.  It
      features:
      
      - A 32.768kHz crystal oscillator which can optionally be used to pass
        through an externally generated clock.
      - A FLL which can be clocked from either the 32.768kHz oscillator or
        the CLKIN pin.
      - A CLKOUT pin which can bring out either the oscillator or the FLL
        output.
      - The 32.768kHz clock can also optionally be brought out on the GPIO
        pins of the device.
      
      This driver fully supports the 32.768kHz oscillator and CLKOUT.  The FLL
      is supported only in AUTO mode, the full flexibility of the FLL cannot
      currently be used.
      
      Due to a lack of access to systems where the core SoC has been converted
      to use the generic clock API this driver has been compile tested only.
      Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      f05259a6
    • Mark Brown's avatar
      clk: Constify struct clk_init_data · dc4cd941
      Mark Brown authored
      Allow drivers to declare their clk_init_data const, the framework really
      shouldn't be modifying the data.
      Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      dc4cd941
    • Rajendra Nayak's avatar
      clk: Add CLK_IS_BASIC flag to identify basic clocks · f7d8caad
      Rajendra Nayak authored
      Most platforms end up using a mix of basic clock types and
      some which use clk_hw_foo struct for filling in custom platform
      information when the clocks don't fit into basic types supported.
      
      In platform code, its useful to know if a clock is using a basic
      type or clk_hw_foo, which helps platforms know if they can
      safely use to_clk_hw_foo to derive the clk_hw_foo pointer from
      clk_hw.
      
      Mark all basic clocks with a CLK_IS_BASIC flag.
      Signed-off-by: default avatarRajendra Nayak <rnayak@ti.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      f7d8caad
    • Rajendra Nayak's avatar
      clk: Add support for rate table based dividers · 357c3f0a
      Rajendra Nayak authored
      Some divider clks do not have any obvious relationship
      between the divider and the value programmed in the
      register. For instance, say a value of 1 could signify divide
      by 6 and a value of 2 could signify divide by 4 etc.
      Also there are dividers where not all values possible
      based on the bitfield width are valid. For instance
      a 3 bit wide bitfield can be used to program a value
      from 0 to 7. However its possible that only 0 to 4
      are valid values.
      
      All these cases need the platform code to pass a simple
      table of divider/value tuple, so the framework knows
      the exact value to be written based on the divider
      calculation and can also do better error checking.
      
      This patch adds support for such rate table based
      dividers and as part of the support adds a new
      registration function 'clk_register_divider_table()'
      and a new macro for static definition
      'DEFINE_CLK_DIVIDER_TABLE'.
      Signed-off-by: default avatarRajendra Nayak <rnayak@ti.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      357c3f0a
    • Rajendra Nayak's avatar
      clk: Add support for power of two type dividers · 6d9252bd
      Rajendra Nayak authored
      Quite often dividers and the value programmed in the
      register have a relation of 'power of two', something like
      value	div
      0	1
      1	2
      2	4
      3	8...
      
      Add support for such dividers as part of clk-divider.
      
      The clk-divider flag 'CLK_DIVIDER_POWER_OF_TWO' should be used
      to define such clocks.
      Signed-off-by: default avatarRajendra Nayak <rnayak@ti.com>
      Signed-off-by: default avatarMike Turquette <mturquette@linaro.org>
      6d9252bd
  3. 08 Jul, 2012 3 commits
  4. 07 Jul, 2012 2 commits
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.linaro.org/people/rmk/linux-arm · cd6407fe
      Linus Torvalds authored
      Pull ARM fixes from Russell King:
       "Last merge window, we had some updates from Al cleaning up the signal
        restart handling.  These have caused some problems on ARM, and while
        Al has some fixes, we have some concerns with Al's patches but we've
        been unsuccesful with discussing this.
      
        We have got to the point where we need to do something, and we've
        decided that the best solution is to revert the appropriate commits
        until Al is able to reply to us.
      
        Also included here are four patches to fix warnings that I've noticed
        in my build system, and one fix for kprobes test code."
      
      * 'fixes' of git://git.linaro.org/people/rmk/linux-arm:
        ARM: fix warning caused by wrongly typed arm_dma_limit
        ARM: fix warnings about atomic64_read
        ARM: 7440/1: kprobes: only test 'sub pc, pc, #1b-2b+8-2' on ARMv6
        ARM: 7441/1: perf: return -EOPNOTSUPP if requested mode exclusion is unavailable
        ARM: 7443/1: Revert "new way of handling ERESTART_RESTARTBLOCK"
        ARM: 7442/1: Revert "remove unused restart trampoline"
        ARM: fix set_domain() macro
        ARM: fix mach-versatile/pci.c warning
      cd6407fe
    • Andy Lutomirski's avatar
      security: Minor improvements to no_new_privs documentation · c540521b
      Andy Lutomirski authored
      The documentation didn't actually mention how to enable no_new_privs.
      This also adds a note about possible interactions between
      no_new_privs and LSMs (i.e. why teaching systemd to set no_new_privs
      is not necessarily a good idea), and it references the new docs
      from include/linux/prctl.h.
      Suggested-by: default avatarRob Landley <rob@landley.net>
      Signed-off-by: default avatarAndy Lutomirski <luto@amacapital.net>
      Acked-by: default avatarKees Cook <keescook@chromium.org>
      Signed-off-by: default avatarJames Morris <james.l.morris@oracle.com>
      c540521b
  5. 06 Jul, 2012 11 commits
  6. 05 Jul, 2012 9 commits
    • Linus Torvalds's avatar
      Merge tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc · c4aed353
      Linus Torvalds authored
      Pull ARM SoC fixes from Arnd Bergmann:
       "Small fixes on multiple ARM platforms
         - A build regression from a previous fix on dove and mv78xx0
         - Two fixes for recently (3.5-rc1) changed mmp/pxa code
         - multiple omap2+ bug fixes
         - two trivial fixes for i.MX
         - one v3.5 regression for mxs"
      
      * tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc:
        ARM: apx4devkit: fix FEC enabling PHY clock
        ARM: OMAP2+: hwmod data: Fix wrong McBSP clock alias on OMAP4
        ARM: OMAP4: hwmod data: temporarily comment out data for the usb_host_fs and aess IP blocks
        ARM: Orion: Fix WDT compile for Dove and MV78xx0
        ARM: mmp: remove mach/gpio-pxa.h
        ARM: imx: assert SCC gate stays enabled
        ARM: OMAP4: TWL6030: ensure sys_nirq1 is mux'd and wakeup enabled
        ARM: OMAP2: Overo: init I2C before MMC to fix MMC suspend/resume failure
        ARM: imx27_visstrim_m10: Do not include <asm/system.h>
        ARM: pxa: hx4700: Fix basic suspend/resume
      c4aed353
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/virt/kvm/kvm · 6bc51545
      Linus Torvalds authored
      Pull KVM fix from Marcelo Tosatti:
       "Memory leak and oops on the x86 mmu code, and sanitization of the
        KVM_IRQFD ioctl."
      
      * git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: MMU: fix shrinking page from the empty mmu
        KVM: fix fault page leak
        KVM: Sanitize KVM_IRQFD flags
        KVM: Add missing KVM_IRQFD API documentation
        KVM: Pass kvm_irqfd to functions
      6bc51545
    • Linus Torvalds's avatar
      Merge branch 'fixes-for-3.5' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds · 24eee627
      Linus Torvalds authored
      Pull leds fix from Bryan Wu:
       "Fix for heartbeat led trigger driver"
      
      * 'fixes-for-3.5' of git://git.kernel.org/pub/scm/linux/kernel/git/cooloney/linux-leds:
        leds: heartbeat: fix bug on panic
      24eee627
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs · 5eecb9cc
      Linus Torvalds authored
      Pull btrfs updates from Chris Mason:
       "I held off on my rc5 pull because I hit an oops during log recovery
        after a crash.  I wanted to make sure it wasn't a regression because
        we have some logging fixes in here.
      
        It turns out that a commit during the merge window just made it much
        more likely to trigger directory logging instead of full commits,
        which exposed an old bug.
      
        The new backref walking code got some additional fixes.  This should
        be the final set of them.
      
        Josef fixed up a corner where our O_DIRECT writes and buffered reads
        could expose old file contents (not stale, just not the most recent).
        He and Liu Bo fixed crashes during tree log recover as well.
      
        Ilya fixed errors while we resume disk balancing operations on
        readonly mounts."
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs:
        Btrfs: run delayed directory updates during log replay
        Btrfs: hold a ref on the inode during writepages
        Btrfs: fix tree log remove space corner case
        Btrfs: fix wrong check during log recovery
        Btrfs: use _IOR for BTRFS_IOC_SUBVOL_GETFLAGS
        Btrfs: resume balance on rw (re)mounts properly
        Btrfs: restore restriper state on all mounts
        Btrfs: fix dio write vs buffered read race
        Btrfs: don't count I/O statistic read errors for missing devices
        Btrfs: resolve tree mod log locking issue in btrfs_next_leaf
        Btrfs: fix tree mod log rewind of ADD operations
        Btrfs: leave critical region in btrfs_find_all_roots as soon as possible
        Btrfs: always put insert_ptr modifications into the tree mod log
        Btrfs: fix tree mod log for root replacements at leaf level
        Btrfs: support root level changes in __resolve_indirect_ref
        Btrfs: avoid waiting for delayed refs when we must not
      5eecb9cc
    • Linus Torvalds's avatar
      Merge branch 'fixes-for-grant' of git://sources.calxeda.com/kernel/linux · 62ad6449
      Linus Torvalds authored
      Pull DT fixes from Rob Herring:
       "Mainly some documentation updates and 2 fixes:
      
         - An export symbol fix for of_platform_populate from Stephen W.
         - A fix for the order compatible entries are matched to ensure the
           first compatible string is matched when there are multiple matches."
      
      Normally these would go through Grant Likely (thus the "fixes-for-grant"
      branch name), but Grant is in the middle of moving to Scotland, and is
      practically offline until sometime in August. So pull directly from Rob.
      
      * 'fixes-for-grant' of git://sources.calxeda.com/kernel/linux:
        of: match by compatible property first
        dt: mc13xxx.txt: Fix gpio number assignment
        dt: fsl-fec.txt: Fix gpio number assignment
        dt: fsl-mma8450.txt: Add missing 'reg' description
        dt: fsl-imx-esdhc.txt: Fix gpio number assignment
        dt: fsl-imx-cspi.txt: Fix comment about GPIOs used for chip selects
        of: Add Avionic Design vendor prefix
        of: export of_platform_populate()
      62ad6449
    • Russell King's avatar
      ARM: fix warning caused by wrongly typed arm_dma_limit · 09b2ad13
      Russell King authored
      arch/arm/mm/init.c: In function 'arm_memblock_init':
      arch/arm/mm/init.c:380: warning: comparison of distinct pointer types lacks a cast
      
      by fixing the typecast in its definition when DMA_ZONE is disabled.
      This was missed in 4986e5c7 (ARM: mm: fix type of the arm_dma_limit
      global variable).
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      09b2ad13
    • Russell King's avatar
      ARM: fix warnings about atomic64_read · b89d607b
      Russell King authored
      Fix:
      net/netfilter/xt_connbytes.c: In function 'connbytes_mt':
      net/netfilter/xt_connbytes.c:43: warning: passing argument 1 of 'atomic64_read' discards qualifiers from pointer target type
      ...
      
      by adding the missing const.
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      b89d607b
    • Rabin Vincent's avatar
      ARM: 7440/1: kprobes: only test 'sub pc, pc, #1b-2b+8-2' on ARMv6 · f8b435bb
      Rabin Vincent authored
      'sub pc, pc, #1b-2b+8-2' results in address<1:0> == '10'.
      
      sub pc, pc, #const (== ADR pc, #const) performs an interworking branch
      (BXWritePC()) on ARMv7+ and a simple branch (BranchWritePC()) on earlier
      versions.
      
      In ARM state, BXWritePC() is UNPREDICTABLE when address<1:0> == '10'.
      
      In ARM state on ARMv6+, BranchWritePC() ignores address<1:0>.  Before
      ARMv6, BranchWritePC() is UNPREDICTABLE if address<1:0> != '00'
      
      So the instruction is UNPREDICTABLE both before and after v6.
      Acked-by: default avatarJon Medhurst <tixy@yxit.co.uk>
      Signed-off-by: default avatarRabin Vincent <rabin.vincent@stericsson.com>
      Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
      f8b435bb
    • Arnd Bergmann's avatar
      Merge tag 'omap-fixes-for-v3.5-rc5' of... · e15ebe05
      Arnd Bergmann authored
      Merge tag 'omap-fixes-for-v3.5-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into fixes
      
      PM related fixes for omaps mostly to get suspend/resume
      working again.
      
      * tag 'omap-fixes-for-v3.5-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
        ARM: OMAP2+: hwmod data: Fix wrong McBSP clock alias on OMAP4
        ARM: OMAP4: hwmod data: temporarily comment out data for the usb_host_fs and aess IP blocks
        ARM: OMAP4: TWL6030: ensure sys_nirq1 is mux'd and wakeup enabled
        ARM: OMAP2: Overo: init I2C before MMC to fix MMC suspend/resume failure
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      e15ebe05