Neil Brown wrote: > On Tuesday September 25, chuck.lever@oracle.com wrote: >> Hi Neil- >> >> Seven more patches for text-based mount.nfs. >> >> I found that it is necessary to do some rather advanced lexical parsing of >> the mount option string in order to handle version/protocol fallback. So I've >> implemented a data structure that can handle the parsing requirements, and >> some wrapper logic to convert the mount option string to the new data >> structure and then convert it back to a string before calling mount(2). >> >> This series introduces the new facility and makes use of it for existing text- >> based mount option processing (like adding "addr=" and so on). In subsequent >> patches I will make more use of the new facility. > > Nice. > > However: The current parsing of mount options (parse_opts, > parse_options) allows for "quotes" around options so that an option > can contain a comma (Gumble SELinux Grumble context=foo,bar Grumble). > Your mount option parsing doesn't allow for this. Should it? I thought it did, but I didn't test this explicitly. It uses the same tokenization logic that legacy NFSv4 does, so I assumed quoting would work correctly. Should I copy the ugly logic from nfsmount.c ? (At this point, not sure the kernel option parser would support quoting either...)