1. 22 8月, 2015 1 次提交
  2. 22 7月, 2015 1 次提交
    • B
      mtd: m25p80: allow arbitrary OF matching for "jedec,spi-nor" · 43163022
      Brian Norris 提交于
      When we added the "jedec,spi-nor" compatible string for use in this
      driver, we added it as a modalias option. The modalias can be derived in
      different ways for platform devices vs. device tree (of_*) matching. But
      for device tree matching (the primary target of this identifier string),
      the modalias is determined from the first entry in the 'compatible'
      property. IOW, the following properties would bind to this driver:
      
      	// Option (a), modalias = "spi-nor"
      	compatible = "jedec,spi-nor";
      
      	// Option (b), modalias = "spi-nor"
      	compatible = "idontknowwhatimdoing,spi-nor";
      
      But the following would not:
      
      	// Option (c), modalias = "shinynewdevice"
      	compatible = "myvendor,shinynewdevice", "jedec,spi-nor";
      
      So, we'd like to match (a) and (c) (even when we don't have an explicit
      entry for "shinynewdevice"), and we'd rather not allow (b).
      
      To do this, we
        (1) always (for devices without specific platform data) pass the
            modalias to the spi-nor library;
        (2) rework the spi-nor library to not reject "bad" names, and
            instead just fall back to autodetection; and
        (3) add the .of_match_table to properly catch all "jedec,spi-nor".
      
      This allows (a) and (c) without warnings, and rejects (b).
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      43163022
  3. 17 6月, 2015 2 次提交
  4. 11 6月, 2015 1 次提交
  5. 02 6月, 2015 1 次提交
    • T
      writeback: separate out include/linux/backing-dev-defs.h · 66114cad
      Tejun Heo 提交于
      With the planned cgroup writeback support, backing-dev related
      declarations will be more widely used across block and cgroup;
      unfortunately, including backing-dev.h from include/linux/blkdev.h
      makes cyclic include dependency quite likely.
      
      This patch separates out backing-dev-defs.h which only has the
      essential definitions and updates blkdev.h to include it.  c files
      which need access to more backing-dev details now include
      backing-dev.h directly.  This takes backing-dev.h off the common
      include dependency chain making it a lot easier to use it across block
      and cgroup.
      
      v2: fs/fat build failure fixed.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Reviewed-by: NJan Kara <jack@suse.cz>
      Cc: Jens Axboe <axboe@kernel.dk>
      Signed-off-by: NJens Axboe <axboe@fb.com>
      66114cad
  6. 23 5月, 2015 1 次提交
  7. 16 5月, 2015 1 次提交
  8. 07 5月, 2015 2 次提交
  9. 06 4月, 2015 2 次提交
    • B
      mtd: m25p80: bind to "nor-jedec" ID, for auto-detection · 1103b851
      Brian Norris 提交于
      Use the new 'nor-jedec' binding to provide automatic detection of flash
      that use the 0x9F READ ID opcode. This can help for use cases where
      platforms just specify compatibility with "m25p80", and then see
      messages like this:
      
        m25p80 spi32766.0: found s25fl256s1, expected m25p80
      
      Instead, they can just specify the generic string and see this:
      
        m25p80 spi32766.0: s25fl256s1 (32768 Kbytes)
      
      Also, update the language about m25p_ids[] to straighten out the
      expectations here. We should no longer need to continuously grow the
      m25p_ids[] table, and in fact, we might want to start removing entries
      which are not used in device trees so far, so we can just default to
      auto-detection as much as possible in the future.
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      Cc: Rafał Miłecki <zajec5@gmail.com>
      1103b851
    • B
      mtd: docg3: remove invalid __exit annotations · 45fd357a
      Brian Norris 提交于
      The .remove callback may be used when detaching a device via sysfs, so
      we can't expect to free up this memory.
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      Acked-by: NRobert Jarzmik <robert.jarzmik@free.fr>
      45fd357a
  10. 12 3月, 2015 1 次提交
  11. 24 2月, 2015 1 次提交
  12. 13 1月, 2015 3 次提交
    • L
      mtd: st_spi_fsm: Fix [-Wsign-compare] build warning · a9b679bf
      Lee Jones 提交于
      drivers/mtd/devices/st_spi_fsm.c:1647:17:
        warning: comparison between signed and unsigned integer expressions
      Signed-off-by: NLee Jones <lee.jones@linaro.org>
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      a9b679bf
    • L
      mtd: st_spi_fsm: Obtain and use EMI clock · 69d5af8d
      Lee Jones 提交于
      ST's Common Clk Framework is now available. This patch ensures the FSM
      makes use of it by obtaining and enabling the EMI clock. If system fails
      to provide the EMI clock, we bomb out.
      Signed-off-by: NLee Jones <lee.jones@linaro.org>
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      69d5af8d
    • L
      mtd: st_spi_fsm: Extend fsm_clear_fifo to handle unwanted bytes · 5ecd3ea1
      Lee Jones 提交于
      Under certain conditions, the SPI-FSM Controller can be left in a state where
      the data FIFO is not entirely empty.  This can lead to problems where subsequent
      data transfers appear to have been shifted by a number of unidentified bytes.
      
      One simple example would be an errant FSM sequence which loaded more data to the
      FIFO than was read by the host.  Another more interesting case results from an
      obscure artefact in the FSM Controller.  When switching from data transfers in
      x4 or x2 mode to data transfers in x1 mode, extraneous bytes will appear in the
      FIFO, unless the previous data transfer was a multiple of 32 cycles (i.e. 8
      bytes for x2, and 16 bytes for x4).  This applies equally whether FSM is being
      operated directly by a S/W driver, or by the SPI boot-controller in FSM-Boot
      mode.  Furthermore, data in the FIFO not only survive a transition between
      FSM-Boot and FSM, but also a S/W reset of IP block [1].
      
      By taking certain precautions, it is possible to prevent the driver from causing
      this type of problem (e.g. ensuring that the host and programmed sequence
      agree on the transfer size, and restricting transfer sizes to multiples of
      32-cycles [2]).  However, at the point the driver is loaded, no assumptions can be
      made regarding the state of the FIFO.  Even if previous S/W drivers have behaved
      correctly, it is impossible to control the number of transactions serviced by
      the controller operating in FSM-Boot.
      
      To address this problem, we ensure the FIFO is cleared during initialisation,
      before performing any FSM operations.  Previously, the fsm_clear_fifo() code was
      capable of detecting and clearing any unwanted 32-bit words from the FIFO.  This
      patch extends the capability to handle an arbitrary number of bytes present in
      the FIFO [3].  Now that the issue is better understood, we also remove the calls
      to fsm_clear_fifo() following the fsm_read() and fsm_write() operations.
      
      The process of actually clearing the FIFO deserves a mention.  While the FIFO
      may contain any number of bytes, the SPI_FAST_SEQ_STA register only reports the
      number of complete 32-bit words present.  Furthermore, data can only be drained
      from the FIFO by reading complete 32-bit words.  With this in mind, a two stage
      process is used to the clear the FIFO:
      
          1. Read any complete 32-bit words from the FIFO, as reported by the
                 SPI_FAST_SEQ_STA register.
      
          2. Mop up any remaining bytes.  At this point, it is not known if there
                 are 0, 1, 2, or 3 bytes in the FIFO.  To handle all cases, a dummy
                 FSM sequence is used to load one byte at a time, until a complete
                 32-bit word is formed; at most, 4 bytes will need to be loaded.
      
      [1] Although this issue has existed since early versions of the SPI-FSM
          controller, its full extent only emerged recently as a consequence of the
          targetpacks starting to use FSM-Boot(x4) as the default configuration.
      
      [2] The requirement to restrict transfers to multiples of 32 cycles was found
          empirically back when DUAL and QUAD mode support was added.  The current
          analysis now gives a satisfactory explanation for this requirement.
      
      [3] Theoretically, it is possible for the FIFO to contain an arbitrary number of
          bits.  However, since there are no known use-cases that leave incomplete
          bytes in the FIFO, only words and bytes are considered here.
      Signed-off-by: NAngus Clark <angus.clark@st.com>
      Signed-off-by: NLee Jones <lee.jones@linaro.org>
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      5ecd3ea1
  13. 01 12月, 2014 1 次提交
  14. 26 11月, 2014 3 次提交
  15. 06 11月, 2014 1 次提交
  16. 05 11月, 2014 2 次提交
  17. 23 10月, 2014 1 次提交
  18. 22 10月, 2014 4 次提交
  19. 20 10月, 2014 1 次提交
  20. 18 10月, 2014 2 次提交
  21. 29 9月, 2014 1 次提交
  22. 23 9月, 2014 1 次提交
  23. 20 8月, 2014 1 次提交
  24. 15 7月, 2014 1 次提交
  25. 06 7月, 2014 2 次提交
  26. 28 5月, 2014 1 次提交
  27. 21 5月, 2014 1 次提交