mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-19 10:53:58 +00:00
The latest cp tool is trying to use the btrfs clone operation that is
implemented via ioctl interface. First of all return ENOTSUP for this operation as a cp fallback to usual method in that case. Secondly, do not print out the message about unimplemented operation.
This commit is contained in:
parent
63cc3320d9
commit
5989b75bdb
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=283496
@ -3596,9 +3596,16 @@ linux_ioctl(struct thread *td, struct linux_ioctl_args *args)
|
||||
sx_sunlock(&linux_ioctl_sx);
|
||||
fdrop(fp, td);
|
||||
|
||||
linux_msg(td, "ioctl fd=%d, cmd=0x%x ('%c',%d) is not implemented",
|
||||
args->fd, (int)(args->cmd & 0xffff),
|
||||
(int)(args->cmd & 0xff00) >> 8, (int)(args->cmd & 0xff));
|
||||
switch (args->cmd & 0xffff) {
|
||||
case LINUX_BTRFS_IOC_CLONE:
|
||||
return (ENOTSUP);
|
||||
|
||||
default:
|
||||
linux_msg(td, "ioctl fd=%d, cmd=0x%x ('%c',%d) is not implemented",
|
||||
args->fd, (int)(args->cmd & 0xffff),
|
||||
(int)(args->cmd & 0xff00) >> 8, (int)(args->cmd & 0xff));
|
||||
break;
|
||||
}
|
||||
|
||||
return (EINVAL);
|
||||
}
|
||||
|
@ -744,6 +744,12 @@
|
||||
#define FBSD_LUSB_MAX 0xffff
|
||||
#define FBSD_LUSB_MIN 0xffdd
|
||||
|
||||
/*
|
||||
* Linux btrfs clone operation
|
||||
*/
|
||||
#define LINUX_BTRFS_IOC_CLONE 0x9409 /* 0x40049409 */
|
||||
|
||||
|
||||
/*
|
||||
* Pluggable ioctl handlers
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user