28 Jan, 2014

2 commits

  • The new memblock_virt APIs are used to replaced old bootmem API.

    We need to allocate page below 4G for swiotlb.

    That should fix regression on Andrew's system that is using swiotlb.

    Signed-off-by: Yinghai Lu
    Cc: Russell King
    Cc: Konrad Rzeszutek Wilk
    Acked-by: Santosh Shilimkar
    Cc: Dave Hansen
    Cc: Ingo Molnar
    Cc: "H. Peter Anvin"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Yinghai Lu
     
  • …kernel/git/konrad/swiotlb

    Pull swiotlb bug-fixes from Konrad Rzeszutek Wilk:
    - Don't DoS with 'swiotlb is full' message.
    - Documentation update.

    * tag 'stable/for-linus-3.14-rc0-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/swiotlb:
    swiotlb: Don't DoS us with 'swiotlb buffer is full' (v2)
    swiotlb: update format

    Linus Torvalds
     

22 Jan, 2014

1 commit

  • Switch to memblock interfaces for early memory allocator instead of
    bootmem allocator. No functional change in beahvior than what it is in
    current code from bootmem users points of view.

    Archs already converted to NO_BOOTMEM now directly use memblock
    interfaces instead of bootmem wrappers build on top of memblock. And
    the archs which still uses bootmem, these new apis just fallback to
    exiting bootmem APIs.

    Signed-off-by: Santosh Shilimkar
    Cc: "Rafael J. Wysocki"
    Cc: Arnd Bergmann
    Cc: Christoph Lameter
    Cc: Greg Kroah-Hartman
    Cc: Grygorii Strashko
    Cc: H. Peter Anvin
    Cc: Johannes Weiner
    Cc: KAMEZAWA Hiroyuki
    Cc: Konrad Rzeszutek Wilk
    Cc: Michal Hocko
    Cc: Paul Walmsley
    Cc: Pavel Machek
    Cc: Russell King
    Cc: Tejun Heo
    Cc: Tony Lindgren
    Cc: Yinghai Lu
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Santosh Shilimkar
     

07 Jan, 2014

1 commit


09 Nov, 2013

1 commit

  • * stefano/swiotlb-xen-9.1:
    swiotlb-xen: fix error code returned by xen_swiotlb_map_sg_attrs
    swiotlb-xen: static inline xen_phys_to_bus, xen_bus_to_phys, xen_virt_to_bus and range_straddles_page_boundary
    grant-table: call set_phys_to_machine after mapping grant refs
    arm,arm64: do not always merge biovec if we are running on Xen
    swiotlb: print a warning when the swiotlb is full
    swiotlb-xen: use xen_dma_map/unmap_page, xen_dma_sync_single_for_cpu/device
    xen: introduce xen_dma_map/unmap_page and xen_dma_sync_single_for_cpu/device
    swiotlb-xen: use xen_alloc/free_coherent_pages
    xen: introduce xen_alloc/free_coherent_pages
    arm64/xen: get_dma_ops: return xen_dma_ops if we are running as xen_initial_domain
    arm/xen: get_dma_ops: return xen_dma_ops if we are running as xen_initial_domain
    swiotlb-xen: introduce xen_swiotlb_set_dma_mask
    xen/arm,arm64: enable SWIOTLB_XEN
    xen: make xen_create_contiguous_region return the dma address
    xen/x86: allow __set_phys_to_machine for autotranslate guests
    arm/xen,arm64/xen: introduce p2m
    arm64: define DMA_ERROR_CODE
    arm: make SWIOTLB available

    Signed-off-by: Konrad Rzeszutek Wilk

    Conflicts:
    arch/arm/include/asm/dma-mapping.h
    drivers/xen/swiotlb-xen.c

    [Conflicts arose b/c "arm: make SWIOTLB available" v8 was in Stefano's
    branch, while I had v9 + Ack from Russel. I also fixed up white-space
    issues]

    Konrad Rzeszutek Wilk
     

25 Oct, 2013

1 commit


24 Oct, 2013

1 commit

  • Tracepoints are only created when Xen support is enabled, but they are
    also referenced within lib/swiotlb.c. So unless Xen support is enabled
    the tracepoints will be missing, therefore causing builds to fail. Fix
    this by moving the tracepoint creation to lib/swiotlb.c, which works
    nicely because the Xen swiotlb support selects the generic swiotlb
    support.

    Signed-off-by: Thierry Reding
    Signed-off-by: Konrad Rzeszutek Wilk

    Thierry Reding
     

03 Oct, 2013

1 commit

  • Ftrace is currently not able to detect when SWIOTLB has to do double buffering.
    Under Xen you can only see it indirectly in function_graph, when
    xen_swiotlb_map_page() doesn't stop after range_straddles_page_boundary(), but
    calls spinlock functions, memcpy() and xen_phys_to_bus() as well. This patch
    introduces the swiotlb:swiotlb_bounced event, which also prints out the
    following informations to help you find out why bouncing happened:

    dev_name: 0000:08:00.0 dma_mask=ffffffffffffffff dev_addr=9149f000 size=32768
    swiotlb_force=0

    If you use Xen, and (dev_addr + size + 1) > dma_mask, the buffer is out of the
    device's DMA range. If swiotlb_force == 1, you should really change the kernel
    parameters. Otherwise, the buffer is not contiguous in mfn space.

    Signed-off-by: Zoltan Kiss
    [v1: Don't print 'swiotlb_force=X', just print swiotlb_force if it is enabled]
    Signed-off-by: Konrad Rzeszutek Wilk

    Zoltan Kiss
     

09 Aug, 2013

1 commit


18 Apr, 2013

1 commit

  • Chao said that kdump does does work well on his system on 3.8
    without extra parameter, even iommu does not work with kdump.
    And now have to append crashkernel_low=Y in first kernel to make
    kdump work.

    We have now modified crashkernel=X to allocate memory beyong 4G (if
    available) and do not allocate low range for crashkernel if the user
    does not specify that with crashkernel_low=Y. This causes regression
    if iommu is not enabled. Without iommu, swiotlb needs to be setup in
    first 4G and there is no low memory available to second kernel.

    Set crashkernel_low automatically if the user does not specify that.

    For system that does support IOMMU with kdump properly, user could
    specify crashkernel_low=0 to save that 72M low ram.

    -v3: add swiotlb_size() according to Konrad.
    -v4: add comments what 8M is for according to hpa.
    also update more crashkernel_low= in kernel-parameters.txt
    -v5: update changelog according to Vivek.
    -v6: Change description about swiotlb referring according to HATAYAMA.

    Reported-by: WANG Chao
    Tested-by: WANG Chao
    Signed-off-by: Yinghai Lu
    Link: http://lkml.kernel.org/r/1366089828-19692-2-git-send-email-yinghai@kernel.org
    Acked-by: Vivek Goyal
    Signed-off-by: H. Peter Anvin

    Yinghai Lu
     

30 Jan, 2013

1 commit

  • Normal boot path on system with iommu support:
    swiotlb buffer will be allocated early at first and then try to initialize
    iommu, if iommu for intel or AMD could setup properly, swiotlb buffer
    will be freed.

    The early allocating is with bootmem, and could panic when we try to use
    kdump with buffer above 4G only, or with memmap to limit mem under 4G.
    for example: memmap=4095M$1M to remove memory under 4G.

    According to Eric, add _nopanic version and no_iotlb_memory to fail
    map single later if swiotlb is still needed.

    -v2: don't pass nopanic, and use -ENOMEM return value according to Eric.
    panic early instead of using swiotlb_full to panic...according to Eric/Konrad.
    -v3: make swiotlb_init to be notpanic, but will affect:
    arm64, ia64, powerpc, tile, unicore32, x86.
    -v4: cleanup swiotlb_init by removing swiotlb_init_with_default_size.

    Suggested-by: Eric W. Biederman
    Signed-off-by: Yinghai Lu
    Link: http://lkml.kernel.org/r/1359058816-7615-36-git-send-email-yinghai@kernel.org
    Reviewed-and-tested-by: Konrad Rzeszutek Wilk
    Cc: Joerg Roedel
    Cc: Ralf Baechle
    Cc: Jeremy Fitzhardinge
    Cc: Kyungmin Park
    Cc: Marek Szyprowski
    Cc: Arnd Bergmann
    Cc: Andrzej Pietrasiewicz
    Cc: linux-mips@linux-mips.org
    Cc: xen-devel@lists.xensource.com
    Cc: virtualization@lists.linux-foundation.org
    Cc: Shuah Khan
    Signed-off-by: H. Peter Anvin

    Yinghai Lu
     

30 Oct, 2012

7 commits

  • Currently swiotlb is the only consumer for swiotlb_bounce. Since that is the
    case it doesn't make much sense to be exporting it so make it a static
    function only.

    In addition we can save a few more lines of code by making it so that it
    accepts the DMA address as a physical address instead of a virtual one. This
    is the last piece in essentially pushing all of the DMA address values to use
    physical addresses in swiotlb.

    In order to clarify things since we now have 2 physical addresses in use
    inside of swiotlb_bounce I am renaming phys to orig_addr, and dma_addr to
    tlb_addr. This way is should be clear that orig_addr is contained within
    io_orig_addr and tlb_addr is an address within the io_tlb_addr buffer.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change makes it so that the sync functionality also uses physical
    addresses. This helps to further reduce the use of virt_to_phys and
    phys_to_virt functions.

    In order to clarify things since we now have 2 physical addresses in use
    inside of swiotlb_tbl_sync_single I am renaming phys to orig_addr, and
    dma_addr to tlb_addr. This way is should be clear that orig_addr is
    contained within io_orig_addr and tlb_addr is an address within the
    io_tlb_addr buffer.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change makes it so that the unmap functionality also uses physical
    addresses. This helps to further reduce the use of virt_to_phys and
    phys_to_virt functions.

    In order to clarify things since we now have 2 physical addresses in use
    inside of swiotlb_tbl_unmap_single I am renaming phys to orig_addr, and
    dma_addr to tlb_addr. This way is should be clear that orig_addr is
    contained within io_orig_addr and tlb_addr is an address within the
    io_tlb_addr buffer.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change makes it so that swiotlb_tbl_map_single will return a physical
    address instead of a virtual address when called. The advantage to this once
    again is that we are avoiding a number of virt_to_phys and phys_to_virt
    translations by working with everything as a physical address.

    One change I had to make in order to support using physical addresses is that
    I could no longer trust 0 to be a invalid physical address on all platforms.
    So instead I made it so that ~0 is returned on error. This should never be a
    valid return value as it implies that only one byte would be available for
    use.

    In order to clarify things since we now have 2 physical addresses in use
    inside of swiotlb_tbl_map_single I am renaming phys to orig_addr, and
    dma_addr to tlb_addr. This way is should be clear that orig_addr is
    contained within io_orig_addr and tlb_addr is an address within the
    io_tlb_addr buffer.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change makes it so that we can avoid virt_to_phys overhead when using the
    io_tlb_overflow_buffer. My original plan was to completely remove the value
    and replace it with a constant but I had seen that there were recent patches
    that stated this couldn't be done until all device drivers that depended on
    that functionality be updated.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change replaces all references to the virtual address for io_tlb_start
    with references to the physical address io_tlb_end. The main advantage of
    replacing the virtual address with a physical address is that we can avoid
    having to do multiple translations from the virtual address to the physical
    one needed for testing an existing DMA address.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     
  • This change replaces all references to the virtual address for io_tlb_end
    with references to the physical address io_tlb_end. The main advantage of
    replacing the virtual address with a physical address is that we can avoid
    having to do multiple translations from the virtual address to the physical
    one needed for testing an existing DMA address.

    Signed-off-by: Alexander Duyck
    Signed-off-by: Konrad Rzeszutek Wilk

    Alexander Duyck
     

22 Aug, 2012

1 commit


30 May, 2012

1 commit

  • Print swiotlb info in a style consistent with the %pR style used elsewhere
    in the kernel. For example:

    -Placing 64MB software IO TLB between ffff88007a662000 - ffff88007e662000
    -software IO TLB at phys 0x7a662000 - 0x7e662000
    +software IO TLB [mem 0x7a662000-0x7e661fff] (64MB) mapped at [ffff88007a662000-ffff88007e661fff]

    Signed-off-by: Bjorn Helgaas
    Cc: Yinghai Lu
    Cc: Konrad Rzeszutek Wilk
    Cc: Ingo Molnar
    Cc: "H. Peter Anvin"
    Cc: Thomas Gleixner
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Bjorn Helgaas
     

25 Mar, 2012

1 commit

  • Pull cleanup of fs/ and lib/ users of module.h from Paul Gortmaker:
    "Fix up files in fs/ and lib/ dirs to only use module.h if they really
    need it.

    These are trivial in scope vs the work done previously. We now have
    things where any few remaining cleanups can be farmed out to arch or
    subsystem maintainers, and I have done so when possible. What is
    remaining here represents the bits that don't clearly lie within a
    single arch/subsystem boundary, like the fs dir and the lib dir.

    Some duplicate includes arising from overlapping fixes from
    independent subsystem maintainer submissions are also quashed."

    Fix up trivial conflicts due to clashes with other include file cleanups
    (including some due to the previous bug.h cleanup pull).

    * tag 'module-for-3.4' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux:
    lib: reduce the use of module.h wherever possible
    fs: reduce the use of module.h wherever possible
    includecheck: delete any duplicate instances of module.h

    Linus Torvalds
     

20 Mar, 2012

1 commit


08 Mar, 2012

1 commit


06 Dec, 2011

1 commit


07 Jun, 2011

1 commit

  • By default the io_tlb_nslabs is set to zero, and gets set to
    whatever value is passed in via swiotlb_init_with_tbl function.
    The default value passed in is 64MB. However, if the user provides
    the 'swiotlb=' the default value is ignored and
    the value provided by the user is used... Except when the SWIOTLB
    is used under Xen - there the default value of 64MB is used and
    the Xen-SWIOTLB has no mechanism to get the 'io_tlb_nslabs' filled
    out by setup_io_tlb_npages functions. This patch provides a function
    for the Xen-SWIOTLB to call to see if the io_tlb_nslabs is set
    and if so use that value.

    Signed-off-by: FUJITA Tomonori
    Signed-off-by: Konrad Rzeszutek Wilk

    FUJITA Tomonori
     

26 Feb, 2011

1 commit

  • swiotlb's map_page wrongly calls panic() when it can't find a buffer fit
    for device's dma mask. It should return an error instead.

    Devices with an odd dma mask (i.e. under 4G) like b44 network card hit
    this bug (the system crashes):

    http://marc.info/?l=linux-kernel&m=129648943830106&w=2

    If swiotlb returns an error, b44 driver can use the own bouncing
    mechanism.

    Reported-by: Chuck Ebbert
    Signed-off-by: FUJITA Tomonori
    Tested-by: Arkadiusz Miskiewicz
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    FUJITA Tomonori
     

02 Nov, 2010

1 commit

  • "gadget", "through", "command", "maintain", "maintain", "controller", "address",
    "between", "initiali[zs]e", "instead", "function", "select", "already",
    "equal", "access", "management", "hierarchy", "registration", "interest",
    "relative", "memory", "offset", "already",

    Signed-off-by: Uwe Kleine-König
    Signed-off-by: Jiri Kosina

    Uwe Kleine-König
     

12 Oct, 2010

2 commits

  • We could call free_bootmem_late() if swiotlb is not used, and
    it will shrink to page alignment.

    So alloc them with page alignment at first, to avoid lose two pages

    before patch:
    [ 0.000000] memblock_x86_reserve_range: [00d3600000, 00d7600000] swiotlb buffer
    [ 0.000000] memblock_x86_reserve_range: [00d7e7ef40, 00d7e9ef40] swiotlb list
    [ 0.000000] memblock_x86_reserve_range: [00d7e3ef40, 00d7e7ef40] swiotlb orig_ad
    [ 0.000000] memblock_x86_reserve_range: [000008a000, 0000092000] swiotlb overflo

    after patch will get
    [ 0.000000] memblock_x86_reserve_range: [00d3600000, 00d7600000] swiotlb buffer
    [ 0.000000] memblock_x86_reserve_range: [00d7e7e000, 00d7e9e000] swiotlb list
    [ 0.000000] memblock_x86_reserve_range: [00d7e3e000, 00d7e7e000] swiotlb orig_ad
    [ 0.000000] memblock_x86_reserve_range: [000008a000, 0000092000] swiotlb overflo

    Signed-off-by: Yinghai Lu
    Acked-by: FUJITA Tomonori
    Cc: Becky Bruce
    Signed-off-by: Konrad Rzeszutek Wilk

    Yinghai Lu
     
  • We don't need to export io_tlb_overflow_buffer. I'll remove
    io_tlb_overflow_buffer completely in the long term though.

    Signed-off-by: FUJITA Tomonori
    Signed-off-by: Konrad Rzeszutek Wilk

    FUJITA Tomonori
     

07 Jun, 2010

5 commits

  • We put the functions dealing with the operations on
    the SWIOTLB buffer in the header and make those functions non-static.
    And also make the functions exported via EXPORT_SYMBOL_GPL.

    See "swiotlb: swiotlb: add swiotlb_tbl_map_single library function" for
    full description of patchset.

    [v2: swiotlb_sync_single_range_for_* no more. Remove usage.]

    Signed-off-by: Konrad Rzeszutek Wilk
    Acked-by: FUJITA Tomonori
    Tested-by: Albert Herranz

    Konrad Rzeszutek Wilk
     
  • .. to catch anybody doing something funky.

    See "swiotlb: swiotlb: add swiotlb_tbl_map_single library function" for
    full description of patchset.

    [v2: swiotlb_sync_single_range_* no more - removed usage]
    [v3: enum dma_data_direction direction -> enum dma_data_direction dir]

    Signed-off-by: Konrad Rzeszutek Wilk
    Acked-by: FUJITA Tomonori
    Tested-by: Albert Herranz

    Konrad Rzeszutek Wilk
     
  • The functions that operate on io_tlb_list/io_tlb_start/io_tlb_orig_addr
    have the prefix 'swiotlb_tbl' now.

    See "swiotlb: swiotlb: add swiotlb_tbl_map_single library function" for
    full description of patchset.

    Signed-off-by: Konrad Rzeszutek Wilk
    Acked-by: FUJITA Tomonori
    Tested-by: Albert Herranz

    Konrad Rzeszutek Wilk
     
  • This enables the caller to initialize swiotlb with its own iotlb
    memory.

    See "swiotlb: swiotlb: add swiotlb_tbl_map_single library function" for
    full description of patchset.

    [v2: changed ..with_tlb to ..with_tbl]

    Signed-off-by: FUJITA Tomonori
    Reviewed-by: Konrad Rzeszutek Wilk
    Tested-by: Albert Herranz

    FUJITA Tomonori
     
  • swiotlb_tbl_map_single() takes the dma address of iotlb instead of
    using swiotlb_virt_to_bus().

    [v2: changed swiotlb_tlb to swiotlb_tbl]
    [v3: changed u64 to dma_addr_t]

    This patch:

    This is a set of patches that separate the address translation
    (virt_to_phys, virt_to_bus, etc) and allocation of the SWIOTLB buffer
    from the SWIOTLB library.

    The idea behind this set of patches is to make it possible to have separate
    mechanisms for translating virtual to physical or virtual to DMA addresses
    on platforms which need an SWIOTLB, and where physical != PCI bus address
    and also to allocate the core IOTLB memory outside SWIOTLB.

    One customers of this is the pv-ops project, which can switch between
    different modes of operation depending on the environment it is running in:
    bare-metal or virtualized (Xen for now). Another is the Wii DMA - used to
    implement the MEM2 DMA facility needed by its EHCI controller (for details:
    http://lkml.org/lkml/2010/5/18/303)

    On bare-metal SWIOTLB is used when there are no hardware IOMMU. In virtualized
    environment it used when PCI pass-through is enabled for the guest. The problems
    with PCI pass-through is that the guest's idea of PFN's is not the real thing.
    To fix that, there is translation layer for PFN->machine frame number and vice-versa.
    To bubble that up to the SWIOTLB layer there are two possible solutions.

    One solution has been to wholesale copy the SWIOTLB, stick it in
    arch/x86/xen/swiotlb.c and modify the virt_to_phys, phys_to_virt and others
    to use the Xen address translation functions. Unfortunately, since the kernel can
    run on bare-metal, there would be big code overlap with the real SWIOTLB.
    (git://git.kernel.org/pub/scm/linux/kernel/git/jeremy/xen.git xen/dom0/swiotlb-new)

    Another approach, which this set of patches explores, is to abstract the
    address translation and address determination functions away from the
    SWIOTLB book-keeping functions. This way the core SWIOTLB library functions
    are present in one place, while the address related functions are in
    a separate library that can be loaded when running under non-bare-metal platform.

    Changelog:
    Since the last posting [v8.2] Konrad has done:
    - Added this changelog in the patch and referenced in the other patches
    this description.
    - 'enum dma_data_direction direction' to 'enum dma.. dir' so to be
    unified.
    [v8-v8.2 changes:]
    - Rolled-up the last two patches in one.
    - Rebased against linus latest. That meant dealing with swiotlb_sync_single_range_* changes.
    - added Acked-by: Fujita Tomonori and Tested-by: Albert Herranz
    [v7-v8 changes:]
    - Minimized the list of exported functions.
    - Integrated Fujita's patches and changed "swiotlb_tlb" to "swiotlb_tbl" in them.
    [v6-v7 changes:]
    - Minimized the amount of exported functions/variable with a prefix of: "swiotbl_tbl".
    - Made the usage of 'int dir' to be 'enum dma_data_direction'.
    [v5-v6 changes:]
    - Made the exported functions/variables have the 'swiotlb_bk' prefix.
    - dropped the checkpatches/other reworks

    Signed-off-by: FUJITA Tomonori
    Reviewed-by: Konrad Rzeszutek Wilk
    Tested-by: Albert Herranz

    FUJITA Tomonori
     

28 May, 2010

1 commit


30 Mar, 2010

1 commit

  • …it slab.h inclusion from percpu.h

    percpu.h is included by sched.h and module.h and thus ends up being
    included when building most .c files. percpu.h includes slab.h which
    in turn includes gfp.h making everything defined by the two files
    universally available and complicating inclusion dependencies.

    percpu.h -> slab.h dependency is about to be removed. Prepare for
    this change by updating users of gfp and slab facilities include those
    headers directly instead of assuming availability. As this conversion
    needs to touch large number of source files, the following script is
    used as the basis of conversion.

    http://userweb.kernel.org/~tj/misc/slabh-sweep.py

    The script does the followings.

    * Scan files for gfp and slab usages and update includes such that
    only the necessary includes are there. ie. if only gfp is used,
    gfp.h, if slab is used, slab.h.

    * When the script inserts a new include, it looks at the include
    blocks and try to put the new include such that its order conforms
    to its surrounding. It's put in the include block which contains
    core kernel includes, in the same order that the rest are ordered -
    alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
    doesn't seem to be any matching order.

    * If the script can't find a place to put a new include (mostly
    because the file doesn't have fitting include block), it prints out
    an error message indicating which .h file needs to be added to the
    file.

    The conversion was done in the following steps.

    1. The initial automatic conversion of all .c files updated slightly
    over 4000 files, deleting around 700 includes and adding ~480 gfp.h
    and ~3000 slab.h inclusions. The script emitted errors for ~400
    files.

    2. Each error was manually checked. Some didn't need the inclusion,
    some needed manual addition while adding it to implementation .h or
    embedding .c file was more appropriate for others. This step added
    inclusions to around 150 files.

    3. The script was run again and the output was compared to the edits
    from #2 to make sure no file was left behind.

    4. Several build tests were done and a couple of problems were fixed.
    e.g. lib/decompress_*.c used malloc/free() wrappers around slab
    APIs requiring slab.h to be added manually.

    5. The script was run on all .h files but without automatically
    editing them as sprinkling gfp.h and slab.h inclusions around .h
    files could easily lead to inclusion dependency hell. Most gfp.h
    inclusion directives were ignored as stuff from gfp.h was usually
    wildly available and often used in preprocessor macros. Each
    slab.h inclusion directive was examined and added manually as
    necessary.

    6. percpu.h was updated not to include slab.h.

    7. Build test were done on the following configurations and failures
    were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my
    distributed build env didn't work with gcov compiles) and a few
    more options had to be turned off depending on archs to make things
    build (like ipr on powerpc/64 which failed due to missing writeq).

    * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
    * powerpc and powerpc64 SMP allmodconfig
    * sparc and sparc64 SMP allmodconfig
    * ia64 SMP allmodconfig
    * s390 SMP allmodconfig
    * alpha SMP allmodconfig
    * um on x86_64 SMP allmodconfig

    8. percpu.h modifications were reverted so that it could be applied as
    a separate patch and serve as bisection point.

    Given the fact that I had only a couple of failures from tests on step
    6, I'm fairly confident about the coverage of this conversion patch.
    If there is a breakage, it's likely to be something in one of the arch
    headers which should be easily discoverable easily on most builds of
    the specific arch.

    Signed-off-by: Tejun Heo <tj@kernel.org>
    Guess-its-ok-by: Christoph Lameter <cl@linux-foundation.org>
    Cc: Ingo Molnar <mingo@redhat.com>
    Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>

    Tejun Heo
     

16 Dec, 2009

1 commit

  • dma_mask is, when interpreted as address, the last valid byte, and hence
    comparison msut also be done using the last valid of the buffer in
    question.

    Also fix the open-coded instances in lib/swiotlb.c.

    Signed-off-by: Jan Beulich
    Cc: FUJITA Tomonori
    Cc: Becky Bruce
    Cc: "Luck, Tony"
    Cc: Benjamin Herrenschmidt
    Cc: Ingo Molnar
    Cc: Thomas Gleixner
    Cc: "H. Peter Anvin"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jan Beulich
     

08 Dec, 2009

1 commit


04 Dec, 2009

1 commit

  • That is "success", "unknown", "through", "performance", "[re|un]mapping"
    , "access", "default", "reasonable", "[con]currently", "temperature"
    , "channel", "[un]used", "application", "example","hierarchy", "therefore"
    , "[over|under]flow", "contiguous", "threshold", "enough" and others.

    Signed-off-by: André Goddard Rosa
    Signed-off-by: Jiri Kosina

    André Goddard Rosa
     

11 Nov, 2009

1 commit

  • POWERPC doesn't expect it to be used.

    This fixes the linux-next build failure reported by
    Stephen Rothwell:

    lib/swiotlb.c: In function 'setup_io_tlb_npages':
    lib/swiotlb.c:114: error: 'swiotlb' undeclared (first use in this function)

    Reported-by: Stephen Rothwell
    Signed-off-by: FUJITA Tomonori
    Cc: peterz@infradead.org
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    FUJITA Tomonori