Received: by 10.192.165.148 with SMTP id m20csp1673011imm; Thu, 3 May 2018 03:36:03 -0700 (PDT) X-Google-Smtp-Source: AB8JxZofwMZ/tffe0bzZUiNQp16QWPa+zAYz+aproQPpyQ8sy/NiLFmsklMnhYYfnak5jT06BsQw X-Received: by 2002:a17:902:28e8:: with SMTP id f95-v6mr23988363plb.250.1525343763629; Thu, 03 May 2018 03:36:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525343763; cv=none; d=google.com; s=arc-20160816; b=Eu75UsDPvNrt2F4u0I+zkMXqYUcGKpzCTEsmp3dBn3qeptAW/au96JIvux2oQg9ibA 0AAhaF1OTGqDjkl+eRseafITn8mUItuGgbarcq/bDhCpm1pQBQqbLiUnZ3YqnUKmgU7Z PUxs7ArR/8peP4CuqLFO47wp6nSt1CX0OY5I4HNHr3qU6ZYSto85YwLAbU/5eXzk/wqZ aL8V25qGhaTVOWo3cGu8YjB95GjhItLW0q1EGLhvS1dxkEdHesBuRvwm6xKW08yX10H2 RsKeTQVlyoCMJn1rr2zEtDQwY+SmL1pXXKi016YdX3dtvHTqcEefOZJiNFnnYmgaxQ6l R0YQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :from:references:cc:to:subject:arc-authentication-results; bh=2tqhr0b/GVsQPYShxyLfewGhJW+lIQxXDjT46xyzt4s=; b=M0TGoOE2HPFI2HYaP7FfUOlYrbciBVm8CjWiNtsOi7kT+r7VRTN5n0F3ITOyK7eUoO zWJYH9j8w3gEbb1mmAQ0P6TMaEQFxwx9ae3eizRcOXxdBEdyLYNql8p1Gl+9Ma1TqE2q C12QvheSYMpHEOapNfW9AOjyBaD4OcyI+A7LNfN1WDSuz/GLNeHy+hpB2O4tntbt/w9B vLDnYhEn54lo0lNbgeNA1dHyje9dG9XRqFmFijrhACxIvorDIoteuGgjPR8i2kx5HTtT GTc4w2vY6++MGvgS+fHuzIlCLrbqoqGZb7KE5fQ22vtpV8S9ldFVzthOjJ1OEuqRigtu nDsw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x10-v6si4590985plv.1.2018.05.03.03.35.49; Thu, 03 May 2018 03:36:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751997AbeECKfb (ORCPT + 99 others); Thu, 3 May 2018 06:35:31 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:44998 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751847AbeECKf3 (ORCPT ); Thu, 3 May 2018 06:35:29 -0400 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w43AZRdS018726 for ; Thu, 3 May 2018 06:35:29 -0400 Received: from e06smtp11.uk.ibm.com (e06smtp11.uk.ibm.com [195.75.94.107]) by mx0a-001b2d01.pphosted.com with ESMTP id 2hqypstxew-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 03 May 2018 06:35:26 -0400 Received: from localhost by e06smtp11.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 3 May 2018 11:34:25 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp11.uk.ibm.com (192.168.101.141) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Thu, 3 May 2018 11:34:22 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w43AYMWD56623338; Thu, 3 May 2018 10:34:22 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6B21A11C050; Thu, 3 May 2018 11:25:56 +0100 (BST) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 390FF11C052; Thu, 3 May 2018 11:25:56 +0100 (BST) Received: from [9.152.224.33] (unknown [9.152.224.33]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTP; Thu, 3 May 2018 11:25:56 +0100 (BST) Subject: Re: [PATCH 05/10] vfio: ccw: Suppress unused event parameter To: Dong Jia Shi Cc: pasic@linux.vnet.ibm.com, linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, cohuck@redhat.com References: <1524149293-12658-1-git-send-email-pmorel@linux.vnet.ibm.com> <1524149293-12658-6-git-send-email-pmorel@linux.vnet.ibm.com> <20180426073618.GA12194@bjsdjshi@linux.vnet.ibm.com> From: Pierre Morel Date: Thu, 3 May 2018 12:34:21 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180426073618.GA12194@bjsdjshi@linux.vnet.ibm.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-TM-AS-GCONF: 00 x-cbid: 18050310-0040-0000-0000-0000045481E8 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18050310-0041-0000-0000-000020F8A792 Message-Id: <24fb88a3-450c-01d3-c00a-2b4bcbe10ca6@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-05-03_05:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1805030100 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 26/04/2018 09:36, Dong Jia Shi wrote: > * Pierre Morel [2018-04-19 16:48:08 +0200]: > >> The fsm_func_t function type definition does not need the event >> parameter since all functions are in a state/event table. > Not sure if this will still be right after you addressed all of the > comments on this version. But no hurt to point out some nits that I > noticed below. > >> Signed-off-by: Pierre Morel >> --- >> drivers/s390/cio/vfio_ccw_fsm.c | 34 +++++++++++----------------------- >> drivers/s390/cio/vfio_ccw_private.h | 5 ++--- >> 2 files changed, 13 insertions(+), 26 deletions(-) >> >> diff --git a/drivers/s390/cio/vfio_ccw_fsm.c b/drivers/s390/cio/vfio_ccw_fsm.c >> index f9855cd..f8ded70 100644 >> --- a/drivers/s390/cio/vfio_ccw_fsm.c >> +++ b/drivers/s390/cio/vfio_ccw_fsm.c >> @@ -55,8 +55,7 @@ static int fsm_io_helper(struct vfio_ccw_private *private) >> } >> } >> >> -static int fsm_notoper(struct vfio_ccw_private *private, >> - enum vfio_ccw_event event) >> +static int fsm_notoper(struct vfio_ccw_private *private) >> { >> struct subchannel *sch = private->sch; >> >> @@ -65,36 +64,31 @@ static int fsm_notoper(struct vfio_ccw_private *private, >> * Probably we should send the machine check to the guest. >> */ >> css_sched_sch_todo(sch, SCH_TODO_UNREG); >> - private->state = VFIO_CCW_STATE_NOT_OPER; >> - return private->state; >> + return VFIO_CCW_STATE_NOT_OPER; > This change should belong to a former patch. > > [...] > >> @@ -109,17 +103,14 @@ static int fsm_disabled_irq(struct vfio_ccw_private *private, >> /* >> * Deal with the ccw command request from the userspace. >> */ >> -static int fsm_io_request(struct vfio_ccw_private *private, >> - enum vfio_ccw_event event) >> +static int fsm_io_request(struct vfio_ccw_private *private) >> { >> - union orb *orb; >> struct ccw_io_region *io_region = &private->io_region; >> + union orb *orb = (union orb *)io_region->orb_area; >> struct mdev_device *mdev = private->mdev; >> >> private->state = VFIO_CCW_STATE_BOXED; >> >> - orb = (union orb *)io_region->orb_area; >> - > Irrelevant change for this patch. > >> io_region->ret_code = cp_init(&private->cp, mdev_dev(mdev), orb); >> if (io_region->ret_code) >> goto err_out; >> @@ -139,15 +130,13 @@ static int fsm_io_request(struct vfio_ccw_private *private, >> return VFIO_CCW_STATE_BUSY; >> >> err_out: >> - private->state = VFIO_CCW_STATE_IDLE; >> - return private->state; >> + return VFIO_CCW_STATE_IDLE; > Should move to other patch. > > [...] > OK, I will move these changes in patch 4/10. -- Pierre Morel Linux/KVM/QEMU in Böblingen - Germany