linux(4): Quiesce unrecognized ioctl warning for F2FS query

On Linux, sqlite probes for underlying F2FS filesystems that support
certain kinds of atomic update with this ioctl.  The expected result on
non-F2FS filesystem (i.e., all FreeBSD filesystems) is any error value.

Minimally implement the ioctl and avoid the warning message.

(This shows up in Linux Chrome, which embeds sqlite.)

Reviewed by:	emaste, trasz
Differential Revision:	https://reviews.freebsd.org/D27050
This commit is contained in:
Conrad Meyer 2020-11-02 18:45:43 +00:00
parent 53efdb55a8
commit 7731194090
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=367279
2 changed files with 6 additions and 0 deletions

View File

@ -3631,6 +3631,7 @@ linux_ioctl_fallback(struct thread *td, struct linux_ioctl_args *args)
switch (args->cmd & 0xffff) {
case LINUX_BTRFS_IOC_CLONE:
case LINUX_F2FS_IOC_GET_FEATURES:
case LINUX_FS_IOC_FIEMAP:
return (ENOTSUP);

View File

@ -707,6 +707,11 @@
#define LINUX_IOCTL_VIDEO2_MIN LINUX_VIDIOC_QUERYCAP
#define LINUX_IOCTL_VIDEO2_MAX LINUX_VIDIOC_UNSUBSCRIBE_EVENT
#define LINUX_F2FS_IOC_GET_FEATURES 0xf50c /* 0x8004f50c */
#define LINUX_IOCTL_F2FS_MIN 0xf500
#define LINUX_IOCTL_F2FS_MAX LINUX_F2FS_IOC_GET_FEATURES
/*
* Our libusb(8) calls emulated within linux(4).
*/