X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=fs%2Fcifs%2Fnetmisc.c;h=3b5a5ce882b63083f492c34a3e1b007fe54be87f;hb=d9f382eff6fbabcd09dad4558d1797c267e9746e;hp=646e1f06941b5c8062e9c8e590c2e2790736ab7f;hpb=0048e1c44a4529d4ea93e6920fa5468730c68c94;p=linux-2.6-omap-h63xx.git diff --git a/fs/cifs/netmisc.c b/fs/cifs/netmisc.c index 646e1f06941..3b5a5ce882b 100644 --- a/fs/cifs/netmisc.c +++ b/fs/cifs/netmisc.c @@ -1,7 +1,7 @@ /* * fs/cifs/netmisc.c * - * Copyright (c) International Business Machines Corp., 2002 + * Copyright (c) International Business Machines Corp., 2002,2008 * Author(s): Steve French (sfrench@us.ibm.com) * * Error mapping routines from Samba libsmb/errormap.c @@ -150,9 +150,7 @@ static int canonicalize_unc(char *cp) if (cp[i] == '\\') break; if (cp[i] == '/') { -#ifdef CONFIG_CIFS_DEBUG2 - cFYI(1, ("change slash to backslash in malformed UNC")); -#endif + cFYI(DBG2, ("change slash to \\ in malformed UNC")); cp[i] = '\\'; return 1; } @@ -178,9 +176,7 @@ cifs_inet_pton(int address_family, char *cp, void *dst) } else if (address_family == AF_INET6) { ret = in6_pton(cp, -1 /* len */, dst , '\\', NULL); } -#ifdef CONFIG_CIFS_DEBUG2 - cFYI(1, ("address conversion returned %d for %s", ret, cp)); -#endif + cFYI(DBG2, ("address conversion returned %d for %s", ret, cp)); if (ret > 0) ret = 1; return ret; @@ -253,7 +249,8 @@ static const struct { ERRDOS, 87, NT_STATUS_INVALID_PARAMETER_MIX}, { ERRHRD, ERRgeneral, NT_STATUS_INVALID_QUOTA_LOWER}, { ERRHRD, ERRgeneral, NT_STATUS_DISK_CORRUPT_ERROR}, { - ERRDOS, ERRbadfile, NT_STATUS_OBJECT_NAME_INVALID}, { /* mapping changed since shell does lookup on * and expects file not found */ + /* mapping changed since shell does lookup on * expects FileNotFound */ + ERRDOS, ERRbadfile, NT_STATUS_OBJECT_NAME_INVALID}, { ERRDOS, ERRbadfile, NT_STATUS_OBJECT_NAME_NOT_FOUND}, { ERRDOS, ERRalreadyexists, NT_STATUS_OBJECT_NAME_COLLISION}, { ERRHRD, ERRgeneral, NT_STATUS_HANDLE_NOT_WAITABLE}, { @@ -820,7 +817,8 @@ map_smb_to_linux_error(struct smb_hdr *smb, int logErr) /* old style errors */ /* DOS class smb error codes - map DOS */ - if (smberrclass == ERRDOS) { /* 1 byte field no need to byte reverse */ + if (smberrclass == ERRDOS) { + /* 1 byte field no need to byte reverse */ for (i = 0; i < sizeof(mapping_table_ERRDOS) / @@ -834,7 +832,8 @@ map_smb_to_linux_error(struct smb_hdr *smb, int logErr) } /* else try next error mapping one to see if match */ } - } else if (smberrclass == ERRSRV) { /* server class of error codes */ + } else if (smberrclass == ERRSRV) { + /* server class of error codes */ for (i = 0; i < sizeof(mapping_table_ERRSRV) / @@ -922,8 +921,8 @@ struct timespec cnvrtDosUnixTm(__u16 date, __u16 time) { struct timespec ts; int sec, min, days, month, year; - SMB_TIME * st = (SMB_TIME *)&time; - SMB_DATE * sd = (SMB_DATE *)&date; + SMB_TIME *st = (SMB_TIME *)&time; + SMB_DATE *sd = (SMB_DATE *)&date; cFYI(1, ("date %d time %d", date, time));