X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;ds=sidebyside;f=arch%2Fpowerpc%2Flib%2Fe2a.c;h=4b72ed8fd50e1da6325f9634ac705f73ebf93791;hb=22a3e233ca08a2ddc949ba1ae8f6e16ec7ef1a13;hp=d2b834887920ac2f63c7fe40166364a88000464d;hpb=3d5271f9883cba7b54762bc4fe027d4172f06db7;p=powerpc.git diff --git a/arch/powerpc/lib/e2a.c b/arch/powerpc/lib/e2a.c index d2b8348879..4b72ed8fd5 100644 --- a/arch/powerpc/lib/e2a.c +++ b/arch/powerpc/lib/e2a.c @@ -1,9 +1,7 @@ /* - * arch/ppc64/lib/e2a.c - * * EBCDIC to ASCII conversion * - * This function moved here from arch/ppc64/kernel/viopath.c + * This function moved here from arch/powerpc/platforms/iseries/viopath.c * * (C) Copyright 2000-2004 IBM Corporation * @@ -105,4 +103,14 @@ unsigned char e2a(unsigned char x) } EXPORT_SYMBOL(e2a); +unsigned char* strne2a(unsigned char *dest, const unsigned char *src, size_t n) +{ + int i; + + n = strnlen(src, n); + for (i = 0; i < n; i++) + dest[i] = e2a(src[i]); + + return dest; +}