Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp484346pxk; Thu, 17 Sep 2020 08:10:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwd1i9hlPKw4B7WuqSEbkjKMhdiHY+oXyCQ5+Yva/8LdmlqKuUlKQvgF/6SWgfS6lXYoduw X-Received: by 2002:aa7:d382:: with SMTP id x2mr34039930edq.108.1600355455193; Thu, 17 Sep 2020 08:10:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600355455; cv=none; d=google.com; s=arc-20160816; b=Qye/dCsMum/KOu7Gd05GrDSh9Il333VgZVccSLvEovGuce6Gdu+0QRFdxXx8gKYQf2 LMr032LryfPzVD2ZJac0LVSAYHkDZZI0yYh01Iwx/aJ3IrUR0VrwtwIjLdXD7Bfi3IUi o3KUCHKKh/lmMIL852HsGW1NArO0lvb3gtw2/kuemc3ySZBORj28BY/JgFM3Q1kr03/K C5fc6JJKx2KN4WQqTcdC8+ZeWE4QFNdCkCK1wVbEvNAZ2kUGKyT2xd1IYn6g+ojwAmDc f5uspsj6HbYCUiST9n2Qgxm4lnLBe3c8TVcBEs4H6OMyiYuAuOZsQLewTzKDy0ss+OZ0 c5Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=yN1U7XibmC1Z1JNtiF9SVSmC7GK3V+g9WikrrvCWKCc=; b=YmEAXXCdeEMQF8Evnm5GzJTHzKNoruRVde2SfKC2u9lkAZ8amQUrssKIJMHyY7CtUw jt3KJ/1L53P4ikb/be7Mbo2WrAwRjOv4JhGsHnWg9tV3boZ5bAmp7EexXfzo2P0fLZAA O7z5h0Q+aduaLWGds68D+jTJPLhISpPCdt2FSNkBk8JGwdP6G/9JYP860scXoqsgsvq3 pwXDQ+OA0VaU8w0aVcCVJGwyTpsjWSCtLyWrSFYbYnUpzeG/BSrHFUoQuHfYqWfEIO+Z 6LsvtQXeUiSZpICNiiFOqL5k0/cmVgfBtDo9oH8tKZC9lGwyz7P3Sc1gB7P71TXC2GFw VR4A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a12si14402399eda.373.2020.09.17.08.10.28; Thu, 17 Sep 2020 08:10:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727418AbgIQPI3 (ORCPT + 99 others); Thu, 17 Sep 2020 11:08:29 -0400 Received: from mout.kundenserver.de ([217.72.192.75]:35939 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727292AbgIQPHx (ORCPT ); Thu, 17 Sep 2020 11:07:53 -0400 X-Greylist: delayed 310 seconds by postgrey-1.27 at vger.kernel.org; Thu, 17 Sep 2020 11:07:47 EDT Received: from mail-qv1-f51.google.com ([209.85.219.51]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.145]) with ESMTPSA (Nemesis) id 1MZTyi-1jxMJo2K0s-00WSnn; Thu, 17 Sep 2020 17:02:34 +0200 Received: by mail-qv1-f51.google.com with SMTP id z18so1114812qvp.6; Thu, 17 Sep 2020 08:02:34 -0700 (PDT) X-Gm-Message-State: AOAM5319yBiLAMHG4Uh9SGJIb67Jv0hLo9ATbvFhGOJ5jEp/ccvakjCd xucmZHJk/84VexMEC5v5ewHBysQ+jj2TzN1nu2A= X-Received: by 2002:a0c:b902:: with SMTP id u2mr27821909qvf.7.1600354952950; Thu, 17 Sep 2020 08:02:32 -0700 (PDT) MIME-Version: 1.0 References: <20200908213715.3553098-1-arnd@arndb.de> <20200912070922.GA1945@infradead.org> In-Reply-To: <20200912070922.GA1945@infradead.org> From: Arnd Bergmann Date: Thu, 17 Sep 2020 17:02:16 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 1/3] scsi: aacraid: improve compat_ioctl handlers To: Christoph Hellwig Cc: Adaptec OEM Raid Solutions , "James E.J. Bottomley" , "Martin K. Petersen" , Balsundar P , Zou Wei , Hannes Reinecke , Sagar Biradar , linux-scsi , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" X-Provags-ID: V03:K1:tdH5RdHOGT01yn08DD7RmONmeXwZPMPHp86hGk2E4IF3abrJQWv 7GqXVsKZhx5IgLInFQaCf7i57pQ+SQZCemxfvQJVb+kwm8O8657lWkSnRV1jcykTgalprah Loldv5Z0o6L3Qm8IILhrA8/fGIW13uJNcu/HTnvLk4PaxGnDuHnQB8dCowjdN5gIJO1nXFQ +8Cfcmi5Jk6hf7mnsXl+Q== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:JsjqpX9DrTI=:F96vHW9RcymRLrildHRtMl uhk7K4gjnVImgJlhtut61+1ZLYkhSuJu4v/VhTbykz6Wx8eEvLtQ9ZrEUJZV0d3Lkk4jK4vsF spLtj3Y2VyuN0koLvY+avkS90l6v7O159t2ZuuG8W2Do6b6dcxYL6VRf3YVF4TSy19J+walh1 0C4r6jWTTb16VdMFXBFk1lpZgdMokg2w06XMVA+r0HJBX733MnmyTPf9fLZs3KwIL5chwfgPm mvw1/831030ZkOvVjzOxc0ovayccO98HnA93JHHgudzgcAxRVZmum9EHgc67UvjwMiDZRlHla 92patzF3ZR2LuPExejLanuun68pcvaTpKK/po9Dh34+rlSxmp9K4R6b6k0wLL28kVFIVRrRVJ fWxTuD8lkXewpBv4szNthZObCaXlIhJTWVkUYmMAaWOglLsV0uODMHZRJ7uBiVF2UzCNcTc76 sMTxlD55tPqBG+niC021b0lXGjcXhFoubbGVL/Uf6Lee6tulKemYGHjJHBfv4QMTVunVtGfMG OxsABQGgzwvBMru9reFgxNnNuHiX7zQ0+Ftx4cB7mxH8hoo/1rwI20gdpPhmP6U7/HhSVix5x rVCE0KnriixFv0OB304Bkj6qV/ZWmC6w71fLN/CDXdAjQKtVAlJbCUR53Qyd2yTL5O+VqQaUA 9tNbNH1rPwiDKmg0rUn2yaNFwA95oiw4SQXCfE9vIXOoZa3aGd3uCOnSzoYG0SBMwhpoTUOGh yE/UWduQ7mwbz5He91ysHKgXanaq95ZRU/K72FUxisC7WyJdpprdoILyZb1qcZOuCyJnP8k0V sYRnecSliKavQ8Xia3d70RkTWy7StJ1dRa8Bl1GKXT072uG8T8DHnmdUQQC3DA9DfThOU/5Ft ExUwvQ3Gdvr4OqHtTQD3JO6D7WRAUbMB4k4sxivTYXOI6bj1OKcB1eENZR9MU3zPHDU1c+k0S owVP7BzS2kT/VxRwHtorGcjPvQ29+xS+ubF83OZIecHoY4gI6CD9b Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Sep 12, 2020 at 9:09 AM Christoph Hellwig wrote: > > On Tue, Sep 08, 2020 at 11:36:21PM +0200, Arnd Bergmann wrote: > > @@ -243,8 +244,23 @@ static int next_getadapter_fib(struct aac_dev * dev, void __user *arg) > > struct list_head * entry; > > unsigned long flags; > > > > - if(copy_from_user((void *)&f, arg, sizeof(struct fib_ioctl))) > > - return -EFAULT; > > + if (in_compat_syscall()) { > > + struct compat_fib_ioctl { > > + u32 fibctx; > > + s32 wait; > > + compat_uptr_t fib; > > + } cf; > > I find the struct declaration deep down in the function a little > annoying. > > But otherwise this looks good; > > Reviewed-by: Christoph Hellwig I got back to these patches now and moved the struct definition, plus fixed a typo I noticed while doing so. Thanks! Arnd