mkdir -m will only set the permissions if it *creates* the directory. Existing directories, with possibly wrong permissions, will not be updated. Use explicit chmod so permissions will always be correct.