@@ -215,9 +215,7 @@ static void access_flags_to_mode(__le32 ace_flags, int type, umode_t *pmode,
215215
216216 if (flags & GENERIC_ALL ) {
217217 * pmode |= (S_IRWXUGO & (* pbits_to_set ));
218- #ifdef CONFIG_CIFS_DEBUG2
219- cFYI (1 , ("all perms" ));
220- #endif
218+ cFYI (DBG2 , ("all perms" ));
221219 return ;
222220 }
223221 if ((flags & GENERIC_WRITE ) ||
@@ -230,9 +228,7 @@ static void access_flags_to_mode(__le32 ace_flags, int type, umode_t *pmode,
230228 ((flags & FILE_EXEC_RIGHTS ) == FILE_EXEC_RIGHTS ))
231229 * pmode |= (S_IXUGO & (* pbits_to_set ));
232230
233- #ifdef CONFIG_CIFS_DEBUG2
234- cFYI (1 , ("access flags 0x%x mode now 0x%x" , flags , * pmode ));
235- #endif
231+ cFYI (DBG2 , ("access flags 0x%x mode now 0x%x" , flags , * pmode ));
236232 return ;
237233}
238234
@@ -261,9 +257,7 @@ static void mode_to_access_flags(umode_t mode, umode_t bits_to_use,
261257 if (mode & S_IXUGO )
262258 * pace_flags |= SET_FILE_EXEC_RIGHTS ;
263259
264- #ifdef CONFIG_CIFS_DEBUG2
265- cFYI (1 , ("mode: 0x%x, access flags now 0x%x" , mode , * pace_flags ));
266- #endif
260+ cFYI (DBG2 , ("mode: 0x%x, access flags now 0x%x" , mode , * pace_flags ));
267261 return ;
268262}
269263
@@ -357,11 +351,9 @@ static void parse_dacl(struct cifs_acl *pdacl, char *end_of_acl,
357351 return ;
358352 }
359353
360- #ifdef CONFIG_CIFS_DEBUG2
361- cFYI (1 , ("DACL revision %d size %d num aces %d" ,
354+ cFYI (DBG2 , ("DACL revision %d size %d num aces %d" ,
362355 le16_to_cpu (pdacl -> revision ), le16_to_cpu (pdacl -> size ),
363356 le32_to_cpu (pdacl -> num_aces )));
364- #endif
365357
366358 /* reset rwx permissions for user/group/other.
367359 Also, if num_aces is 0 i.e. DACL has no ACEs,
@@ -494,13 +486,11 @@ static int parse_sec_desc(struct cifs_ntsd *pntsd, int acl_len,
494486 le32_to_cpu (pntsd -> gsidoffset ));
495487 dacloffset = le32_to_cpu (pntsd -> dacloffset );
496488 dacl_ptr = (struct cifs_acl * )((char * )pntsd + dacloffset );
497- #ifdef CONFIG_CIFS_DEBUG2
498- cFYI (1 , ("revision %d type 0x%x ooffset 0x%x goffset 0x%x "
489+ cFYI (DBG2 , ("revision %d type 0x%x ooffset 0x%x goffset 0x%x "
499490 "sacloffset 0x%x dacloffset 0x%x" ,
500491 pntsd -> revision , pntsd -> type , le32_to_cpu (pntsd -> osidoffset ),
501492 le32_to_cpu (pntsd -> gsidoffset ),
502493 le32_to_cpu (pntsd -> sacloffset ), dacloffset ));
503- #endif
504494/* cifs_dump_mem("owner_sid: ", owner_sid_ptr, 64); */
505495 rc = parse_sid (owner_sid_ptr , end_of_acl );
506496 if (rc )
@@ -635,9 +625,7 @@ static int set_cifs_acl(struct cifs_ntsd *pnntsd, __u32 acllen,
635625 struct super_block * sb ;
636626 struct cifs_sb_info * cifs_sb ;
637627
638- #ifdef CONFIG_CIFS_DEBUG2
639- cFYI (1 , ("set ACL for %s from mode 0x%x" , path , inode -> i_mode ));
640- #endif
628+ cFYI (DBG2 , ("set ACL for %s from mode 0x%x" , path , inode -> i_mode ));
641629
642630 if (!inode )
643631 return (rc );
@@ -668,9 +656,7 @@ static int set_cifs_acl(struct cifs_ntsd *pnntsd, __u32 acllen,
668656 }
669657
670658 rc = CIFSSMBSetCIFSACL (xid , cifs_sb -> tcon , fid , pnntsd , acllen );
671- #ifdef CONFIG_CIFS_DEBUG2
672- cFYI (1 , ("SetCIFSACL rc = %d" , rc ));
673- #endif
659+ cFYI (DBG2 , ("SetCIFSACL rc = %d" , rc ));
674660 if (unlock_file == TRUE)
675661 atomic_dec (& open_file -> wrtPending );
676662 else
@@ -688,9 +674,7 @@ void acl_to_uid_mode(struct inode *inode, const char *path)
688674 u32 acllen = 0 ;
689675 int rc = 0 ;
690676
691- #ifdef CONFIG_CIFS_DEBUG2
692- cFYI (1 , ("converting ACL to mode for %s" , path ));
693- #endif
677+ cFYI (DBG2 , ("converting ACL to mode for %s" , path ));
694678 pntsd = get_cifs_acl (& acllen , inode , path );
695679
696680 /* if we can retrieve the ACL, now parse Access Control Entries, ACEs */
@@ -711,9 +695,7 @@ int mode_to_acl(struct inode *inode, const char *path, __u64 nmode)
711695 struct cifs_ntsd * pntsd = NULL ; /* acl obtained from server */
712696 struct cifs_ntsd * pnntsd = NULL ; /* modified acl to be sent to server */
713697
714- #ifdef CONFIG_CIFS_DEBUG2
715- cFYI (1 , ("set ACL from mode for %s" , path ));
716- #endif
698+ cFYI (DBG2 , ("set ACL from mode for %s" , path ));
717699
718700 /* Get the security descriptor */
719701 pntsd = get_cifs_acl (& acllen , inode , path );
@@ -735,16 +717,12 @@ int mode_to_acl(struct inode *inode, const char *path, __u64 nmode)
735717
736718 rc = build_sec_desc (pntsd , pnntsd , acllen , inode , nmode );
737719
738- #ifdef CONFIG_CIFS_DEBUG2
739- cFYI (1 , ("build_sec_desc rc: %d" , rc ));
740- #endif
720+ cFYI (DBG2 , ("build_sec_desc rc: %d" , rc ));
741721
742722 if (!rc ) {
743723 /* Set the security descriptor */
744724 rc = set_cifs_acl (pnntsd , acllen , inode , path );
745- #ifdef CONFIG_CIFS_DEBUG2
746- cFYI (1 , ("set_cifs_acl rc: %d" , rc ));
747- #endif
725+ cFYI (DBG2 , ("set_cifs_acl rc: %d" , rc ));
748726 }
749727
750728 kfree (pnntsd );
0 commit comments