summaryrefslogtreecommitdiffstats
path: root/arch/parisc/hpux
diff options
context:
space:
mode:
authorMilind Arun Choudhary <milindchoudhary@gmail.com>2007-04-01 13:06:46 +0530
committerKyle McMartin <kyle@athena.road.mcmartin.ca>2007-05-22 23:56:14 -0400
commitea74342900dbe79f2a31ed3609b9e2bdb5c7198c (patch)
treefafb38b50f34624b1eb0efc44bfe7a1cdeadccd4 /arch/parisc/hpux
parent7022672e4046fac4699aa5f8ff2a5213b7ec4ff9 (diff)
downloadblackbird-op-linux-ea74342900dbe79f2a31ed3609b9e2bdb5c7198c.tar.gz
blackbird-op-linux-ea74342900dbe79f2a31ed3609b9e2bdb5c7198c.zip
[PARISC] ROUND_UP macro cleanup in arch/parisc
ROUND_UP macro cleanup, use ALIGN where ever appropriate Signed-off-by: Milind Arun Choudhary <milindchoudhary@gmail.com> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'arch/parisc/hpux')
-rw-r--r--arch/parisc/hpux/fs.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/arch/parisc/hpux/fs.c b/arch/parisc/hpux/fs.c
index d86e15776779..f2042e6466a4 100644
--- a/arch/parisc/hpux/fs.c
+++ b/arch/parisc/hpux/fs.c
@@ -21,6 +21,7 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
+#include <linux/kernel.h>
#include <linux/mm.h>
#include <linux/sched.h>
#include <linux/file.h>
@@ -69,7 +70,6 @@ struct getdents_callback {
};
#define NAME_OFFSET(de) ((int) ((de)->d_name - (char __user *) (de)))
-#define ROUND_UP(x) (((x)+sizeof(long)-1) & ~(sizeof(long)-1))
static int filldir(void * __buf, const char * name, int namlen, loff_t offset,
u64 ino, unsigned d_type)
@@ -77,7 +77,7 @@ static int filldir(void * __buf, const char * name, int namlen, loff_t offset,
struct hpux_dirent __user * dirent;
struct getdents_callback * buf = (struct getdents_callback *) __buf;
ino_t d_ino;
- int reclen = ROUND_UP(NAME_OFFSET(dirent) + namlen + 1);
+ int reclen = ALIGN(NAME_OFFSET(dirent) + namlen + 1, sizeof(long));
buf->error = -EINVAL; /* only used if we fail.. */
if (reclen > buf->count)
@@ -102,7 +102,6 @@ static int filldir(void * __buf, const char * name, int namlen, loff_t offset,
}
#undef NAME_OFFSET
-#undef ROUND_UP
int hpux_getdents(unsigned int fd, struct hpux_dirent __user *dirent, unsigned int count)
{
OpenPOWER on IntegriCloud