Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1231141 > unrolled thread
| Started by | Dan Williams <dan.j.williams@intel.com> |
|---|---|
| First post | 2015-09-23 06:50 +0200 |
| Last post | 2015-09-28 20:50 +0200 |
| Articles | 5 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 01/15] avr32: convert to asm-generic/memory_model.h Dan Williams <dan.j.williams@intel.com> - 2015-09-23 06:50 +0200
Re: [PATCH 01/15] avr32: convert to asm-generic/memory_model.h Christoph Hellwig <hch@infradead.org> - 2015-09-24 17:20 +0200
Re: [PATCH 01/15] avr32: convert to asm-generic/memory_model.h Dan Williams <dan.j.williams@intel.com> - 2015-09-26 02:40 +0200
Re: [PATCH 01/15] avr32: convert to asm-generic/memory_model.h Christoph Hellwig <hch@infradead.org> - 2015-09-26 22:20 +0200
RE: [PATCH 01/15] avr32: convert to asm-generic/memory_model.h "Luck, Tony" <tony.luck@intel.com> - 2015-09-28 20:50 +0200
| From | Dan Williams <dan.j.williams@intel.com> |
|---|---|
| Date | 2015-09-23 06:50 +0200 |
| Subject | [PATCH 01/15] avr32: convert to asm-generic/memory_model.h |
| Message-ID | <qbKae-20h-17@gated-at.bofh.it> |
Switch avr32/include/asm/page.h to use the common defintions for pfn_to_page(), page_to_pfn(), and ARCH_PFN_OFFSET. Signed-off-by: Dan Williams <dan.j.williams@intel.com> --- arch/avr32/include/asm/page.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/avr32/include/asm/page.h b/arch/avr32/include/asm/page.h index f805d1cb11bc..c5d2a3e2c62f 100644 --- a/arch/avr32/include/asm/page.h +++ b/arch/avr32/include/asm/page.h @@ -83,11 +83,9 @@ static inline int get_order(unsigned long size) #ifndef CONFIG_NEED_MULTIPLE_NODES -#define PHYS_PFN_OFFSET (CONFIG_PHYS_OFFSET >> PAGE_SHIFT) +#define ARCH_PFN_OFFSET (CONFIG_PHYS_OFFSET >> PAGE_SHIFT) -#define pfn_to_page(pfn) (mem_map + ((pfn) - PHYS_PFN_OFFSET)) -#define page_to_pfn(page) ((unsigned long)((page) - mem_map) + PHYS_PFN_OFFSET) -#define pfn_valid(pfn) ((pfn) >= PHYS_PFN_OFFSET && (pfn) < (PHYS_PFN_OFFSET + max_mapnr)) +#define pfn_valid(pfn) ((pfn) >= ARCH_PFN_OFFSET && (pfn) < (ARCH_PFN_OFFSET + max_mapnr)) #endif /* CONFIG_NEED_MULTIPLE_NODES */ #define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT) @@ -101,4 +99,6 @@ static inline int get_order(unsigned long size) */ #define HIGHMEM_START 0x20000000UL +#include <asm-generic/memory_model.h> + #endif /* __ASM_AVR32_PAGE_H */ -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Christoph Hellwig <hch@infradead.org> |
|---|---|
| Date | 2015-09-24 17:20 +0200 |
| Message-ID | <qcgtt-6OZ-27@gated-at.bofh.it> |
| In reply to | #1231141 |
On Wed, Sep 23, 2015 at 12:41:18AM -0400, Dan Williams wrote: > Switch avr32/include/asm/page.h to use the common defintions for > pfn_to_page(), page_to_pfn(), and ARCH_PFN_OFFSET. This was the last architecture not using asm-generic/memory_model.h, so it might be time to move it to linux/ or even fold it into an existing header. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Dan Williams <dan.j.williams@intel.com> |
|---|---|
| Date | 2015-09-26 02:40 +0200 |
| Message-ID | <qcLGW-KJ-13@gated-at.bofh.it> |
| In reply to | #1232186 |
On Thu, Sep 24, 2015 at 8:10 AM, Christoph Hellwig <hch@infradead.org> wrote: > On Wed, Sep 23, 2015 at 12:41:18AM -0400, Dan Williams wrote: >> Switch avr32/include/asm/page.h to use the common defintions for >> pfn_to_page(), page_to_pfn(), and ARCH_PFN_OFFSET. > > This was the last architecture not using asm-generic/memory_model.h, > so it might be time to move it to linux/ or even fold it into an > existing header. I went to go attempt this, but ia64 is still a holdout, as its DISCONTIGMEM setup can't use the generic memory_model definitions. #ifdef CONFIG_DISCONTIGMEM # define page_to_pfn(page) ((unsigned long) (page - vmem_map)) # define pfn_to_page(pfn) (vmem_map + (pfn)) #else # include <asm-generic/memory_model.h> #endif #else # include <asm-generic/memory_model.h> #endif -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Christoph Hellwig <hch@infradead.org> |
|---|---|
| Date | 2015-09-26 22:20 +0200 |
| Message-ID | <qd46S-1XH-11@gated-at.bofh.it> |
| In reply to | #1233119 |
On Fri, Sep 25, 2015 at 05:36:36PM -0700, Dan Williams wrote: > I went to go attempt this, but ia64 is still a holdout, as its > DISCONTIGMEM setup can't use the generic memory_model definitions. > > #ifdef CONFIG_DISCONTIGMEM > # define page_to_pfn(page) ((unsigned long) (page - vmem_map)) > # define pfn_to_page(pfn) (vmem_map + (pfn)) > #else > # include <asm-generic/memory_model.h> > #endif > #else > # include <asm-generic/memory_model.h> > #endif Seems like we should simply introduce a CONFIG_VMEM_MAP for ia64 to get this started. Does my memory trick me or did we used to have vmem_map on other architectures as well but managed to get rid of it everywhere but on ia64? -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | "Luck, Tony" <tony.luck@intel.com> |
|---|---|
| Date | 2015-09-28 20:50 +0200 |
| Message-ID | <qdLES-7JW-3@gated-at.bofh.it> |
| In reply to | #1233293 |
> Seems like we should simply introduce a CONFIG_VMEM_MAP for ia64 > to get this started. Does my memory trick me or did we used to have > vmem_map on other architectures as well but managed to get rid of it > everywhere but on ia64? I think ia64 hung onto this because of the SGI sn1 platforms. They were even more discontiguous than even SPARSEMEM_EXTREME could handle -Tony -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web