linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] arch-x86-pci-swiotlb-cleanup-patch
@ 2009-08-13 14:18 Marin Mitov
  2009-08-13 20:29 ` Ingo Molnar
  0 siblings, 1 reply; 2+ messages in thread
From: Marin Mitov @ 2009-08-13 14:18 UTC (permalink / raw)
  To: linux-kernel; +Cc: linux-pci, Jesse Barnes

Hi all,

This is a simple cleanup patch for arch/x86/kernel/pci-swiotlb.c file.

Deleted functions are already in lib/swiotlb.c, so no need to be duplicated.

The patch is against linux-2.6.31-rc5, compile/run tested on x86_64.

Best regards,

Marin Mitov

Signed-off-by: Marin Mitov <mitov@issp.bas.bg>

=====================================================
--- a/arch/x86/kernel/pci-swiotlb.c	2009-08-13 16:05:28.000000000 +0300
+++ b/arch/x86/kernel/pci-swiotlb.c	2009-08-13 16:13:09.000000000 +0300
@@ -13,31 +13,6 @@
 
 int swiotlb __read_mostly;
 
-void * __init swiotlb_alloc_boot(size_t size, unsigned long nslabs)
-{
-	return alloc_bootmem_low_pages(size);
-}
-
-void *swiotlb_alloc(unsigned order, unsigned long nslabs)
-{
-	return (void *)__get_free_pages(GFP_DMA | __GFP_NOWARN, order);
-}
-
-dma_addr_t swiotlb_phys_to_bus(struct device *hwdev, phys_addr_t paddr)
-{
-	return paddr;
-}
-
-phys_addr_t swiotlb_bus_to_phys(struct device *hwdev, dma_addr_t baddr)
-{
-	return baddr;
-}
-
-int __weak swiotlb_arch_range_needs_mapping(phys_addr_t paddr, size_t size)
-{
-	return 0;
-}
-
 static void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
 					dma_addr_t *dma_handle, gfp_t flags)
 {

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] arch-x86-pci-swiotlb-cleanup-patch
  2009-08-13 14:18 [PATCH] arch-x86-pci-swiotlb-cleanup-patch Marin Mitov
@ 2009-08-13 20:29 ` Ingo Molnar
  0 siblings, 0 replies; 2+ messages in thread
From: Ingo Molnar @ 2009-08-13 20:29 UTC (permalink / raw)
  To: Marin Mitov, FUJITA Tomonori; +Cc: linux-kernel, linux-pci, Jesse Barnes


* Marin Mitov <mitov@issp.bas.bg> wrote:

> Hi all,
> 
> This is a simple cleanup patch for arch/x86/kernel/pci-swiotlb.c 
> file.
> 
> Deleted functions are already in lib/swiotlb.c, so no need to be 
> duplicated.
> 
> The patch is against linux-2.6.31-rc5, compile/run tested on 
> x86_64.
> 
> Best regards,
> 
> Marin Mitov
> 
> Signed-off-by: Marin Mitov <mitov@issp.bas.bg>
> 
> =====================================================
> --- a/arch/x86/kernel/pci-swiotlb.c	2009-08-13 16:05:28.000000000 +0300
> +++ b/arch/x86/kernel/pci-swiotlb.c	2009-08-13 16:13:09.000000000 +0300
> @@ -13,31 +13,6 @@
>  
>  int swiotlb __read_mostly;
>  
> -void * __init swiotlb_alloc_boot(size_t size, unsigned long nslabs)
> -{
> -	return alloc_bootmem_low_pages(size);
> -}
> -
> -void *swiotlb_alloc(unsigned order, unsigned long nslabs)
> -{
> -	return (void *)__get_free_pages(GFP_DMA | __GFP_NOWARN, order);
> -}
> [...]

Fujita Tomonori has already done this in these swiotlb commits:

  bb52196: swiotlb: remove unused swiotlb_alloc()
  3885123: swiotlb: remove unused swiotlb_alloc_boot()

about a month ago. You can find those changes in -tip:

  http://people.redhat.com/mingo/tip.git/README

and in linux-next as well.

	Ingo

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-08-13 20:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-13 14:18 [PATCH] arch-x86-pci-swiotlb-cleanup-patch Marin Mitov
2009-08-13 20:29 ` Ingo Molnar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).