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