On 10/28/2010 11:17 PM, Steve French wrote: > On Thu, Oct 28, 2010 at 11:41 AM, Shirish Pargaonkar > <shirishpargaonkar@xxxxxxxxx> wrote: >> On Thu, Oct 28, 2010 at 11:19 AM, Suresh Jayaraman <sjayaraman@xxxxxxx> wrote: >>> On 10/28/2010 09:12 PM, Steve French wrote: >>>> What is the code flow then on Windows9x, OS/2 or in the EOPNOSUPP >>>> case? ïSeems strange that we don't retry with legacy or in the case >>>> where the dialect (or previous call) shows that we don't support the >>>> infolevel. >>> >>> If CIFSSMBOpen fails, the callers seem to be fall back to legacy open using >>> SMBLegacyOpen(). >>> >>> cifs_open() >>> >>> ï ï ï ... >>> ï ï ï ïif (tcon->ses->capabilities & CAP_NT_SMBS) >>> ï ï ï ï ï ï ï ïrc = CIFSSMBOpen(xid, tcon, full_path, disposition, >>> ï ï ï ï ï ï ï ï ï ï ï ï desiredAccess, CREATE_NOT_DIR, &netfid, &oplock, buf, >>> ï ï ï ï ï ï ï ï ï ï ï ï cifs_sb->local_nls, cifs_sb->mnt_cifs_flags >>> ï ï ï ï ï ï ï ï ï ï ï ï ï ï ï ï & CIFS_MOUNT_MAP_SPECIAL_CHR); >>> ï ï ï ïelse >>> ï ï ï ï ï ï ï ïrc = -EIO; /* no NT SMB support fall into legacy open below */ >>> >>> ï ï ï ïif (rc == -EIO) { >>> ï ï ï ï ï ï ï ï/* Old server, try legacy style OpenX */ >>> ï ï ï ï ï ï ï ïrc = SMBLegacyOpen(xid, tcon, full_path, disposition, >>> ï ï ï ï ï ï ï ï ï ï ï ïdesiredAccess, CREATE_NOT_DIR, &netfid, &oplock, buf, >>> ï ï ï ï ï ï ï ï ï ï ï ïcifs_sb->local_nls, cifs_sb->mnt_cifs_flags >>> ï ï ï ï ï ï ï ï ï ï ï ï ï ï ï ï& CIFS_MOUNT_MAP_SPECIAL_CHR); >>> ï ï ï ï} >>> >> This is a general comment but should cifs client be using (server) >> dialect specific set of smb commands >> and those smb commands specific info levels instead of sending a >> command and trying downlevel / legacy >> if that command failed with "operation not supported"? > > We can do the former for smb2, but not for cifs unfortunately. > > For cifs there are lots of cases where a dialect doesn't support an > infolevel it should (or even viceversa). So that means this patch is applicable to CIFS as is, right? -- Suresh Jayaraman -- To unsubscribe from this list: send the line "unsubscribe linux-cifs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html