12 Jan, 2012

20 commits

  • c31b50e (mmc: core: Use delayed work in clock gating framework,
    2011-11-14) missed a few things during review:

    o A useless pr_info()

    o milliseconds was written as two words

    o The sysfs file had units in its output

    Fix all three problems.

    Signed-off-by: Stephen Boyd
    Cc: Sujit Reddy Thumma
    Signed-off-by: Chris Ball

    Stephen Boyd
     
  • Signed-off-by: Axel Lin
    Acked-by: Adrian Hunter
    Signed-off-by: Chris Ball

    Axel Lin
     
  • Enable boot partitions to be read-only locked until next power on via
    a sysfs entry. There will be one sysfs entry for each boot partition:

    /sys/block/mmcblkXbootY/ro_lock_until_next_power_on

    Each boot partition is locked by writing 1 to its file.

    Signed-off-by: Johan Rudholm
    Signed-off-by: John Beckett
    Signed-off-by: Chris Ball

    Johan Rudholm
     
  • sdhci-s3c updates pm_caps from platform data for SDIO PM.

    Signed-off-by: Sangwook Lee
    Signed-off-by: Chris Ball

    Sangwook Lee
     
  • Add a function mmc_detect_card_removed() which upper layers can use to
    determine immediately if a card has been removed. This function should
    be called after an I/O request fails so that all queued I/O requests
    can be errored out immediately instead of waiting for the card device
    to be removed.

    Signed-off-by: Adrian Hunter
    Acked-by: Sujit Reddy Thumma
    Signed-off-by: Chris Ball

    Adrian Hunter
     
  • Signed-off-by: Cong Wang
    Acked-by: Guennadi Liakhovetski
    Signed-off-by: Chris Ball

    Cong Wang
     
  • This patch converts the drivers in drivers/mmc/host/* to use the
    module_platform_driver() macro which makes the code smaller and a bit
    simpler.

    Signed-off-by: Axel Lin
    Acked-by: "Michał Mirosław"
    Acked-by: David Brown
    Acked-by: Viresh Kumar
    Acked-by: Guennadi Liakhovetski
    Acked-by: Sascha Hauer
    Acked-by: Wolfram Sang
    Acked-by: Anton Vorontsov
    Signed-off-by: Chris Ball

    Axel Lin
     
  • In ancient times it was necessary to manually initialize the bus field of an
    spi_driver to spi_bus_type. These days this is done in spi_driver_register(),
    so we can drop the manual assignment.

    The patch was generated using the following coccinelle semantic patch:
    //
    @@
    identifier _driver;
    @@
    struct spi_driver _driver = {
    .driver = {
    - .bus = &spi_bus_type,
    },
    };
    //

    Signed-off-by: Lars-Peter Clausen
    Signed-off-by: Chris Ball

    Lars-Peter Clausen
     
  • Replace ilog2(__rounddown_pow_of_two(x)) with the equivalent but much
    simpler fls(x) - 1.

    Reported-by: Andrew Morton
    Signed-off-by: Guennadi Liakhovetski
    Signed-off-by: Chris Ball

    Guennadi Liakhovetski
     
  • If the read or write buffer size associated with the command sent
    through the mmc_blk_ioctl is zero, do not prepare data buffer.

    This enables a ioctl(2) call to for instance send a MMC_SWITCH to set
    a byte in the ext_csd.

    Signed-off-by: Johan Rudholm
    Signed-off-by: Chris Ball

    Johan Rudholm
     
  • 1ms is enough for hardware to change the clock to stable.
    100ms is too long in the tasklet.

    Signed-off-by: Tony Lin
    CC: Xiaobo Xie
    CC: Anton Vorontsov
    Signed-off-by: Chris Ball

    Tony Lin
     
  • If max_seg_size is unaligned, mmc_test_map_sg() may create sg element
    sizes that are not aligned with 512 byte. Fix, align max_seg_size at
    mmc_test_area_init().

    Signed-off-by: Per Forlin
    Signed-off-by: Chris Ball

    Per Forlin
     
  • Signed-off-by: Per Forlin
    Signed-off-by: Chris Ball

    Per Forlin
     
  • This patch adds support for sdio UHS cards per the version 3.0
    spec.

    UHS mode is only enabled for version 3.0 cards when both the
    host and the controller support UHS modes.

    1.8v signaling support is removed if both the card and the
    host do not support UHS. This is done to maintain
    compatibility and some system/card combinations break when
    1.8v signaling is enabled when the host does not support UHS.

    Signed-off-by: Philip Rakity
    Signed-off-by: Aaron Lu
    Reviewed-by: Arindam Nath
    Tested-by: Bing Zhao
    Signed-off-by: Chris Ball

    Philip Rakity
     
  • Suspend/Resume is missing from sdhci-spear driver. This patch adds
    support for suspend/resume for this driver.

    Signed-off-by: Viresh Kumar
    Signed-off-by: Chris Ball

    Viresh Kumar
     
  • Current clock gating framework disables the MCI clock as soon as the
    request is completed and enables it when a request arrives. This aggressive
    clock gating framework, when enabled, cause following issues:

    When there are back-to-back requests from the Queue layer, we unnecessarily
    end up disabling and enabling the clocks between these requests since 8MCLK
    clock cycles is a very short duration compared to the time delay between
    back to back requests reaching the MMC layer. This overhead can effect the
    overall performance depending on how long the clock enable and disable
    calls take which is platform dependent. For example on some platforms we
    can have clock control not on the local processor, but on a different
    subsystem and the time taken to perform the clock enable/disable can add
    significant overhead.

    Also if the host controller driver decides to disable the host clock too
    when mmc_set_ios function is called with ios.clock=0, it adds additional
    delay and it is highly possible that the next request had already arrived
    and unnecessarily blocked in enabling the clocks. This is seen frequently
    when the processor is executing at high speeds and in multi-core platforms
    thus reduces the overall throughput compared to if clock gating is
    disabled.

    Fix this by delaying turning off the clocks by posting request on
    delayed workqueue. Also cancel the unscheduled pending work, if any,
    when there is access to card.

    sysfs entry is provided to tune the delay as needed, default
    value set to 200ms.

    Signed-off-by: Sujit Reddy Thumma
    Acked-by: Linus Walleij
    Signed-off-by: Chris Ball

    Sujit Reddy Thumma
     
  • No functional change; adds macros for card manufacturer IDs.

    Signed-off-by: Chris Ball
    Cc: Andrei E. Warkentin
    Cc: Stefan Nilsson XK

    Chris Ball
     
  • This patch is to expose the actual SDCLK frequency in
    /sys/kernel/debug/mmcX/ios entry.

    For example, if the max clk for a normal speed card is 20MHz this
    is reported in /sys/kernel/debug/mmcX/ios. Unfortunately the actual
    SDCLK frequency (i.e. Baseclock / divisor) is not reported at all:
    for example, in that case, on Arasan HC, it should be 48/4=12 (MHz).

    Signed-off-by: Giuseppe Cavallaro
    Acked-by: Adrian Hunter
    Signed-off-by: Chris Ball

    Giuseppe CAVALLARO
     
  • This patch allows any block size to be set on the SDIO link,
    and still have an arbitrary sized packet (adjusted in size by
    using sdio_align_size) transferred in an optimal way
    (preferably one transfer).

    Previously if the block size was larger than the default of
    512 bytes and the transfer size was exactly one block size
    (possibly thanks to using sdio_align_size to get an optimal
    transfer size), it was sent as a number of byte transfers instead
    of one block transfer. Also if the number of blocks was
    (max_blocks * N) + 1, the tranfer would be conducted with a number
    of blocks and finished off with a number of byte transfers.

    When doing this change it was also possible to break out the quirk
    for broken byte mode in a much cleaner way, and collect the logic of
    when to do byte or block transfer in one function instead of two.

    Signed-off-by: Stefan Nilsson XK
    Signed-off-by: Ulf Hansson
    Acked-by: Linus Walleij
    Signed-off-by: Chris Ball

    Stefan Nilsson XK
     
  • Add new macros for the high speed 50MHz case, rather than having
    a confusing reuse of the value for UHS SDR50, which is 100MHz.

    Reported-by: Aaron Lu
    Signed-off-by: Chris Ball

    Qiang Liu
     

24 Dec, 2011

1 commit


23 Dec, 2011

8 commits

  • * 'for-linus' of git://neil.brown.name/md:
    md/bitmap: It is OK to clear bits during recovery.
    md: don't give up looking for spares on first failure-to-add
    md/raid5: ensure correct assessment of drives during degraded reshape.
    md/linear: fix hot-add of devices to linear arrays.

    Linus Torvalds
     
  • commit d0a4bb492772ce5c4bdfba3744a99ed6f6fb238f introduced a
    regression which is annoying but fairly harmless.

    When writing to an array that is undergoing recovery (a spare
    in being integrated into the array), writing to the array will
    set bits in the bitmap, but they will not be cleared when the
    write completes.

    For bits covering areas that have not been recovered yet this is not a
    problem as the recovery will clear the bits. However bits set in
    already-recovered region will stay set and never be cleared.
    This doesn't risk data integrity. The only negatives are:
    - next time there is a crash, more resyncing than necessary will
    be done.
    - the bitmap doesn't look clean, which is confusing.

    While an array is recovering we don't want to update the
    'events_cleared' setting in the bitmap but we do still want to clear
    bits that have very recently been set - providing they were written to
    the recovering device.

    So split those two needs - which previously both depended on 'success'
    and always clear the bit of the write went to all devices.

    Signed-off-by: NeilBrown

    NeilBrown
     
  • Before performing a recovery we try to remove any spares that
    might not be working, then add any that might have become relevant.

    Currently we abort on the first spare that cannot be added.
    This is a false optimisation.
    It is conceivable that - depending on rules in the personality - a
    subsequent spare might be accepted.
    Also the loop does other things like count the available spares and
    reset the 'recovery_offset' value.

    If we abort early these might not happen properly.

    So remove the early abort.

    In particular if you have an array what is undergoing recovery and
    which has extra spares, then the recovery may not restart after as
    reboot as the could of 'spares' might end up as zero.

    Reported-by: Anssi Hannula
    Signed-off-by: NeilBrown

    NeilBrown
     
  • While reshaping a degraded array (as when reshaping a RAID0 by first
    converting it to a degraded RAID4) we currently get confused about
    which devices are in_sync. In most cases we get it right, but in the
    region that is being reshaped we need to treat non-failed devices as
    in-sync when we have the data but haven't actually written it out yet.

    Reported-by: Adam Kwolek
    Signed-off-by: NeilBrown

    NeilBrown
     
  • commit d70ed2e4fafdbef0800e73942482bb075c21578b
    broke hot-add to a linear array.
    After that commit, metadata if not written to devices until they
    have been fully integrated into the array as determined by
    saved_raid_disk. That patch arranged to clear that field after
    a recovery completed.

    However for linear arrays, there is no recovery - the integration is
    instantaneous. So we need to explicitly clear the saved_raid_disk
    field.

    Signed-off-by: NeilBrown

    NeilBrown
     
  • * 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb:
    USB: Fix usb/isp1760 build on sparc
    usb: gadget: epautoconf: do not change number of streams
    usb: dwc3: core: fix cached revision on our structure
    usb: musb: fix reset issue with full speed device

    Linus Torvalds
     
  • * 'upstream-linus' of git://github.com/jgarzik/libata-dev:
    pata_of_platform: Add missing CONFIG_OF_IRQ dependency.

    Linus Torvalds
     
  • Signed-off-by: David S. Miller
    Signed-off-by: Jeff Garzik

    David Miller
     

22 Dec, 2011

5 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
    net: Add a flow_cache_flush_deferred function
    ipv4: reintroduce route cache garbage collector
    net: have ipconfig not wait if no dev is available
    sctp: Do not account for sizeof(struct sk_buff) in estimated rwnd
    asix: new device id
    davinci-cpdma: fix locking issue in cpdma_chan_stop
    sctp: fix incorrect overflow check on autoclose
    r8169: fix Config2 MSIEnable bit setting.
    llc: llc_cmsg_rcv was getting called after sk_eat_skb.
    net: bpf_jit: fix an off-one bug in x86_64 cond jump target
    iwlwifi: update SCD BC table for all SCD queues
    Revert "Bluetooth: Revert: Fix L2CAP connection establishment"
    Bluetooth: Clear RFCOMM session timer when disconnecting last channel
    Bluetooth: Prevent uninitialized data access in L2CAP configuration
    iwlwifi: allow to switch to HT40 if not associated
    iwlwifi: tx_sync only on PAN context
    mwifiex: avoid double list_del in command cancel path
    ath9k: fix max phy rate at rate control init
    nfc: signedness bug in __nci_request()
    iwlwifi: do not set the sequence control bit is not needed

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-2.6:
    mfd: Include linux/io.h to jz4740-adc
    mfd: Use request_threaded_irq for twl4030-irq instead of irq_set_chained_handler
    mfd: Base interrupt for twl4030-irq must be one-shot
    mfd: Handle tps65910 clear-mask correctly
    mfd: add #ifdef CONFIG_DEBUG_FS guard for ab8500_debug_resources
    mfd: Fix twl-core oops while calling twl_i2c_* for unbound driver
    mfd: include linux/module.h for ab5500-debugfs
    mfd: Update wm8994 active device checks for WM1811
    mfd: Set tps6586x bits if new value is different from the old one
    mfd: Set da903x bits if new value is different from the old one
    mfd: Set adp5520 bits if new value is different from the old one
    mfd: Add missed free_irq in da903x_remove

    Linus Torvalds
     
  • * 'for-greg' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb:
    usb: gadget: epautoconf: do not change number of streams
    usb: dwc3: core: fix cached revision on our structure
    usb: musb: fix reset issue with full speed device

    Greg Kroah-Hartman
     
  • This commit:

    commit 8f5d621543cb064d2989fc223d3c2bc61a43981e
    Author: Joachim Foerster
    Date: Mon Oct 10 18:06:54 2011 +0200

    usb/isp1760: Let OF bindings depend on general CONFIG_OF instead of PPC_OF .

    To be able to use the driver on other OF-aware architectures, too.
    And add necessary OF related #includes to fix compilation error.

    Signed-off-by: Joachim Foerster
    Signed-off-by: Greg Kroah-Hartman

    enabled the build on all CONFIG_OF architectures, but it cannot do
    this.

    This driver depends upon CONFIG_OF_IRQ but not all CONFIG_OF platforms
    support that infrastructure, in particular Sparc does not so the
    build fails.

    Please push a patch like the following to Linus so that this code only
    gets built where it actually should.

    --------------------
    usb/isp1760: Add missing CONFIG_OF_IRQ dependency on OF code.

    Signed-off-by: David S. Miller
    Signed-off-by: Greg Kroah-Hartman

    David Miller
     
  • …wireless into for-davem

    John W. Linville
     

21 Dec, 2011

6 commits