xref: /dflybsd-src/sys/dev/drm/include/asm/memory_model.h (revision 541aa16d079e4d6d10bc1f45e153d4bd79e3fa5d)
1*541aa16dSFrançois Tigeot /*
2*541aa16dSFrançois Tigeot  * Copyright (c) 2016 François Tigeot
3*541aa16dSFrançois Tigeot  * All rights reserved.
4*541aa16dSFrançois Tigeot  *
5*541aa16dSFrançois Tigeot  * Redistribution and use in source and binary forms, with or without
6*541aa16dSFrançois Tigeot  * modification, are permitted provided that the following conditions
7*541aa16dSFrançois Tigeot  * are met:
8*541aa16dSFrançois Tigeot  * 1. Redistributions of source code must retain the above copyright
9*541aa16dSFrançois Tigeot  *    notice unmodified, this list of conditions, and the following
10*541aa16dSFrançois Tigeot  *    disclaimer.
11*541aa16dSFrançois Tigeot  * 2. Redistributions in binary form must reproduce the above copyright
12*541aa16dSFrançois Tigeot  *    notice, this list of conditions and the following disclaimer in the
13*541aa16dSFrançois Tigeot  *    documentation and/or other materials provided with the distribution.
14*541aa16dSFrançois Tigeot  *
15*541aa16dSFrançois Tigeot  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16*541aa16dSFrançois Tigeot  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17*541aa16dSFrançois Tigeot  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18*541aa16dSFrançois Tigeot  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19*541aa16dSFrançois Tigeot  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20*541aa16dSFrançois Tigeot  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21*541aa16dSFrançois Tigeot  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22*541aa16dSFrançois Tigeot  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23*541aa16dSFrançois Tigeot  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24*541aa16dSFrançois Tigeot  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25*541aa16dSFrançois Tigeot  */
26*541aa16dSFrançois Tigeot 
27*541aa16dSFrançois Tigeot #ifndef _ASM_MEMORY_MODEL_H_
28*541aa16dSFrançois Tigeot #define _ASM_MEMORY_MODEL_H_
29*541aa16dSFrançois Tigeot 
30*541aa16dSFrançois Tigeot #define page_to_pfn(page)	OFF_TO_IDX(VM_PAGE_TO_PHYS(page))
31*541aa16dSFrançois Tigeot 
32*541aa16dSFrançois Tigeot #endif	/* _ASM_MEMORY_MODEL_H_ */
33