Re: [PATCH RFC RESEND 6/6] iommu/riscv: support nested iommu for flushing cache

From: Jason Gunthorpe
Date: Tue May 07 2024 - 12:27:13 EST


On Tue, May 07, 2024 at 11:35:16PM +0800, Zong Li wrote:
> > > + default:
> > > + pr_warn("The user command: 0x%x is not supported\n", opcode);
> > > + return -EOPNOTSUPP;
> >
> > No userspace triggerable warnings.
>
> I don't complete understand about this. Could I know whether we should
> suppress the message and return the error directly, or if we should
> convert the warning to an error (i.e. pr_err)?

A userspace system call should never print to dmesg. Return an error
code. Put a pr_debug if you really care.

Jason