rpc: gss: eliminate print_hexl()'s

Dumping all this data to the logs is wasteful (even when debugging is turned
off), and creates too much output to be useful when it's turned on.

Fix a minor style bug or two while we're at it.

Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
J. Bruce Fields
2006-12-04 20:22:31 -05:00
committed by Trond Myklebust
parent 2b577f1f14
commit 8fc7500bb8
6 changed files with 2 additions and 66 deletions

View File

@@ -94,46 +94,6 @@ struct gss_auth {
static void gss_destroy_ctx(struct gss_cl_ctx *);
static struct rpc_pipe_ops gss_upcall_ops;
void
print_hexl(u32 *p, u_int length, u_int offset)
{
u_int i, j, jm;
u8 c, *cp;
dprintk("RPC: print_hexl: length %d\n",length);
dprintk("\n");
cp = (u8 *) p;
for (i = 0; i < length; i += 0x10) {
dprintk(" %04x: ", (u_int)(i + offset));
jm = length - i;
jm = jm > 16 ? 16 : jm;
for (j = 0; j < jm; j++) {
if ((j % 2) == 1)
dprintk("%02x ", (u_int)cp[i+j]);
else
dprintk("%02x", (u_int)cp[i+j]);
}
for (; j < 16; j++) {
if ((j % 2) == 1)
dprintk(" ");
else
dprintk(" ");
}
dprintk(" ");
for (j = 0; j < jm; j++) {
c = cp[i+j];
c = isprint(c) ? c : '.';
dprintk("%c", c);
}
dprintk("\n");
}
}
EXPORT_SYMBOL(print_hexl);
static inline struct gss_cl_ctx *
gss_get_ctx(struct gss_cl_ctx *ctx)
{