From patchwork Wed Sep 20 08:28:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: xiaolei wang X-Patchwork-Id: 142319 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:172:b0:3f2:4152:657d with SMTP id h50csp4015154vqi; Wed, 20 Sep 2023 03:05:05 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF1Ot2vtO9imzw0anRiaww48eNUtoj8P6FiaGJKziW96tLjs3B6GwvZVPHt2jKIggtnWdoW X-Received: by 2002:a17:902:e5d1:b0:1c3:c5b5:8a94 with SMTP id u17-20020a170902e5d100b001c3c5b58a94mr2161591plf.18.1695204305009; Wed, 20 Sep 2023 03:05:05 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1695204304; cv=pass; d=google.com; s=arc-20160816; b=cY/Qpc1jvrX4EkB912klkAZLyMO4bq3NU+iLhBvO3Ah7MzTCtJ+WgOEQeHpLiB72Op ahO/OhF+bW7t/op/+YFOts1pF1pt5dzYcEH3NEuRrEWQEUHnX8Jq8k94NJCXheylo9K9 FVv6RtrEuCWNHTl1VM6kuFm4ctdV9+ngTC0v32//R+6OivJr7DUU3lO0izEjoUbnCl/O 188SHJADYalmwZYYSRmrcsc0QoVAgycJWSFmSHYqlbJskuU1EcOT4IPvSN2Y16BqIW/v mu/5s/WfX1ryqAyM3I90PZnWm8ne/68rus0egxCVOEqSDpF7NvYotNYVoJ7fvydEqwZ3 a/tw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :message-id:date:subject:cc:to:from:dkim-signature; bh=zkrBJP+mr6DHy6EgeSYXaYFHaZ4B5eQKZG2J+6skekE=; fh=bOrDi9FFn3gVTuePyCB1iPXvgZDSFqLjduJ+mcZZCG8=; b=LJ2Yu6KjETcbX5pLxBujXWijqi6DPvZBVNYEtAcCbhpWzU4ZDzKVQB2iGmE4n6jqXI hov08NdN0OKFPWXvUJStQGfo9h99tHPPgE1i55khtRPS1wsk8peaKc/9qWz4dZJD0IRY 6USYrGuU4ZkvBgh9KZ3StlhOk58cjwx2o01ldJ89kv/66gQCqnX4z9dNUkxuDFKJrPJd SbjahJqghZ5yr5+tGRIUfuEcT5RFgje3c3VWmFhu7VIWnVVpKi4yk2DwPkWQy2jVVfHN aKsigYLLfjJ6SLaHrzarIjT1ym4nTAIkWnfYDWF3duhzIqQXoof03f+n1PNJN8B+onYF 9Dwg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@windriver.com header.s=PPS06212021 header.b=dxj1eQsN; arc=pass (i=1 spf=pass spfdomain=windriver.com dkim=pass dkdomain=windriver.com dmarc=pass fromdomain=windriver.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=windriver.com Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id u11-20020a170902e80b00b001bbbbb61c71si12113384plg.399.2023.09.20.03.05.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 03:05:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@windriver.com header.s=PPS06212021 header.b=dxj1eQsN; arc=pass (i=1 spf=pass spfdomain=windriver.com dkim=pass dkdomain=windriver.com dmarc=pass fromdomain=windriver.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=windriver.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 2EFBB808D2AD; Wed, 20 Sep 2023 01:31:17 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232192AbjITIam (ORCPT + 26 others); Wed, 20 Sep 2023 04:30:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49550 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231269AbjITIak (ORCPT ); Wed, 20 Sep 2023 04:30:40 -0400 Received: from mx0b-0064b401.pphosted.com (mx0b-0064b401.pphosted.com [205.220.178.238]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 52E799E; Wed, 20 Sep 2023 01:30:34 -0700 (PDT) Received: from pps.filterd (m0250812.ppops.net [127.0.0.1]) by mx0a-0064b401.pphosted.com (8.17.1.22/8.17.1.22) with ESMTP id 38K4LiQs027614; Wed, 20 Sep 2023 08:29:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=windriver.com; h=from:to:cc:subject:date:message-id:content-transfer-encoding :content-type:mime-version; s=PPS06212021; bh=zkrBJP+mr6DHy6EgeS YXaYFHaZ4B5eQKZG2J+6skekE=; b=dxj1eQsNsmEig/IfMHhrNrXkUlMVEeXucQ Xs3BPUFXlinwT0zHMWVgHmozd9SChL8IYksp1tVZeIoOkDDCwOZqAZ6PA0DzWBs8 r/oGoa7mvYt6BpnofuqH9lGmXMjlAkRPKIYIV4HjROX8O+SbskMWouaxUJQFL17w jaws+1+5xGz1OOBsAqQ6hQQIWbbRpnzQ67lsdaDzREoTrU9WZzNDbZDoPHLoE+uy rGmzbmYdw4HNXWfiw5UmOM7PEUFHM2P/nJH/WJT5xglMu/5sXwUDN0DZ1zXZycZJ eg//6WFOqeVi5CCFVSd4/FuncKlCFPnHdzM7PL07Dd3qq+M2IDTA== Received: from nam04-bn8-obe.outbound.protection.outlook.com (mail-bn8nam04lp2043.outbound.protection.outlook.com [104.47.74.43]) by mx0a-0064b401.pphosted.com (PPS) with ESMTPS id 3t53b5u9pm-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 20 Sep 2023 08:29:20 +0000 (GMT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=X4Yoq6mvTpQhjLEnjD8zk2M0suUbTGGNDe8VQjYfVW2SBkdimjRNnZnH7YLgSXlvMO6bS/Eh9wXZloJ5tKx4jtQsMYBonfB+cn8JeIaTEbBGtKwDGzwrKIJpQdD9RFv0xQBGTpVSGpvS2iwetCN1q2LZWH65dkSPQkpmgNBWtmWo6gEs8799zwIHaD4C7z/7zAeZ8fOe40Waqu0E4qgIB1P/zlcN6kRCybtp9ycmtL0gTKYVKXOPnw4IgqIJ4ERSw6oTrVqqiIhPZKLqbeU3xS3cSnhgCWsi1U6o0E5l2T4nAlaAcZ68BjhaDnZj8/PKvrYSPEf752M8szxdR2z/eQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zkrBJP+mr6DHy6EgeSYXaYFHaZ4B5eQKZG2J+6skekE=; b=b9iLKtMHOnh3yRlxMwlYdIoCZzahnFURYCD7rHSgAIE41FpLiCT27z2mZfa/HrWONqQlokomu5koQ0sC6JR9RszIPEE1Sh3TWiiVW6obhf3imRD7Eb4yrwuU1TxrxrdY9VVQNqBvakJbT6mBOSXsTekZ4AniaH5cKgd0PDM6xa3WW4xOx49XP83CRR8LPsWzrwJQ5tYzU0sWx1kb/N7MM4wYt4ww4lVp1YO0enidqSF/guL2l7ckRqOOGCT1aouHdTclNmSGO5HwKfRTKx8uRuXIqT92lUqsiLn5yCLwU7mcwlWIeKoF0PGyDQdg7R0cYIB/udApF2cokJSv9EEN8A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=windriver.com; dmarc=pass action=none header.from=windriver.com; dkim=pass header.d=windriver.com; arc=none Received: from MW5PR11MB5764.namprd11.prod.outlook.com (2603:10b6:303:197::8) by PH0PR11MB4774.namprd11.prod.outlook.com (2603:10b6:510:40::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6792.28; Wed, 20 Sep 2023 08:29:17 +0000 Received: from MW5PR11MB5764.namprd11.prod.outlook.com ([fe80::43f3:ec40:692c:b924]) by MW5PR11MB5764.namprd11.prod.outlook.com ([fe80::43f3:ec40:692c:b924%7]) with mapi id 15.20.6792.026; Wed, 20 Sep 2023 08:29:16 +0000 From: Xiaolei Wang To: peter.chen@kernel.org, pawell@cadence.com, gregkh@linuxfoundation.org, pavel@denx.de, rogerq@kernel.org Cc: linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] usb: cdns3: Modify the return value of cdns_set_active () to void when CONFIG_PM_SLEEP is disabled Date: Wed, 20 Sep 2023 16:28:56 +0800 Message-Id: <20230920082856.1782284-1-xiaolei.wang@windriver.com> X-Mailer: git-send-email 2.25.1 X-ClientProxiedBy: SI1PR02CA0019.apcprd02.prod.outlook.com (2603:1096:4:1f4::15) To MW5PR11MB5764.namprd11.prod.outlook.com (2603:10b6:303:197::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MW5PR11MB5764:EE_|PH0PR11MB4774:EE_ X-MS-Office365-Filtering-Correlation-Id: 302c3211-e27d-4853-fdc9-08dbb9b3ada0 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: oDFJlwS1BYNUpK3xP69JROImYI5GbnnDu+Ln86O3CGf2uQ++uAHZV6D669JraBvBEDn+/jurQpgq2MCAJwzomTQI26qDWx9S5g/XPgRcJnUE6TLAHiYid9Sq/kmLLY9rlTYQqr7jIXSUtEe5WXoh7MjGj7isjTOb+4Rhv5kuM5XoZe8GNrYd2ZRl3/rlsgSy//IKjGn2JKtsclxpBRKCjNeE/+wdY7tZU2IK+pmMTnukzmjqbtqUeCnqePwiRg6cuYq65ydfhpL+9mkvkqkX6PgYb/kijBIrnkjn/CoDBvWDLt/3N3c0+uU/PxEf4sSxZPA5lKaMZjBGzZST3UoW1Wg3n/V1DbBdhDHbhpGPqeOpIfoh+ebzAVHnPtETDcYKE/8zv01N+GfnUUNvHdhbs6ylkrlmdOWvsOQnzkx+XL1ZLv+/7CYuQ+6MAbEHh0VJGYj2P2HwHWFlWQrLhMJHSTOqcxpCR2KvDD/1/WZzQ5epAa1ad5F6+6sjApiUnLPU6Qw4KQ5ECGu40hC97bHiYLOHSe05QAlHUFDdDJbmbqWSf7S9qBDf3V67RSD0+t5XMOHMi0/H+noQ02gHE8losI94SZ5qhg5LKYFoewSAsIs= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW5PR11MB5764.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(39850400004)(376002)(366004)(396003)(346002)(136003)(186009)(451199024)(1800799009)(316002)(66556008)(66476007)(478600001)(66946007)(38350700002)(38100700002)(966005)(2906002)(8936002)(8676002)(41300700001)(4326008)(86362001)(44832011)(5660300002)(83380400001)(6506007)(2616005)(6512007)(6666004)(52116002)(6486002)(1076003)(26005)(36756003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: vR1PNduhUeYoCrWq/JBR2gGsr9bNlalvELHxta18H6Cl0uwKnTXTpp9SPCMGecpewncyDNVn3Kx4YuCulgYSm1t5iuDw6xu7qDhWVVTWhEVAYjnM2K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oLREF4SVUXdKqnu5hRbPCXGqGPyXbUs257pw9nYb4ZhjWT0gU39HdT7SOVTPuA3IdzPLAOdnPUI3o2SB2pDz9rsdhTO9bc5SAcYfkLc5mmaETRupBfIBFBJvxICGb5bZA9ABhVI/T6M9K5JnNSKZavwj6xnKt+X/002IW3JOwnif493MrAlcZI7kisCcwvLRkWwNDX18k8OJmx000sq/MegrHiji/I9M6GuvMEh2NNeDMV9n8ra4bOkXg4hgG9/YBsR1kCttqwn3aw5MNyStDl/gKRFUVoIPzemAADWnhhchKYDIBvf9g5g4VaMHsxzYKlBiN6yVauoSHSOTdGb4PWFRqDyvFT52iUhKH9MfhGOxUZ4wVUOcjdABRZy7hNADKkVm1wS6uGnjOSm7qPxs9oajcktqO1NmSW3mNEBay718Wy5ZYLs7CjJA== X-OriginatorOrg: windriver.com X-MS-Exchange-CrossTenant-Network-Message-Id: 302c3211-e27d-4853-fdc9-08dbb9b3ada0 X-MS-Exchange-CrossTenant-AuthSource: MW5PR11MB5764.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Sep 2023 08:29:16.9341 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 8ddb2873-a1ad-4a18-ae4e-4644631433be X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Th2ZUNr140seGm7sloyNu3/qgojcFSb297oKWM3IOLp2MC1WgVb6gEx/g2QuyPXwX5ZA7umNLLok8FuHtpRJsgppSgwEMdu2/9AadDcYrHU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR11MB4774 X-Proofpoint-GUID: aAjPRAdUumIkK3qDpyBkdm4mImw5_oaK X-Proofpoint-ORIG-GUID: aAjPRAdUumIkK3qDpyBkdm4mImw5_oaK X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.267,Aquarius:18.0.980,Hydra:6.0.601,FMLib:17.11.176.26 definitions=2023-09-20_03,2023-09-19_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxlogscore=654 priorityscore=1501 lowpriorityscore=0 mlxscore=0 spamscore=0 adultscore=0 suspectscore=0 impostorscore=0 bulkscore=0 clxscore=1015 phishscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2308100000 definitions=main-2309200067 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 20 Sep 2023 01:31:17 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1777550549405288186 X-GMAIL-MSGID: 1777550549405288186 The return type of cdns_set_active () is inconsistent depending on whether CONFIG_PM_SLEEP is enabled, so the return value is modified to void type. Reported-by: Pavel Machek Closes: https://lore.kernel.org/all/ZP7lIKUzD68XA91j@duo.ucw.cz/ Fixes: 2319b9c87fe2 ("usb: cdns3: Put the cdns set active part outside the spin lock") Cc: stable@vger.kernel.org Signed-off-by: Xiaolei Wang Reviewed-by: Pavel Machek Reviewed-by: Roger Quadros v2: * Add Cc: stable@vger.kernel.org --- drivers/usb/cdns3/core.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/usb/cdns3/core.h b/drivers/usb/cdns3/core.h index 4a4dbc2c1561..81a9c9d6be08 100644 --- a/drivers/usb/cdns3/core.h +++ b/drivers/usb/cdns3/core.h @@ -131,8 +131,7 @@ void cdns_set_active(struct cdns *cdns, u8 set_active); #else /* CONFIG_PM_SLEEP */ static inline int cdns_resume(struct cdns *cdns) { return 0; } -static inline int cdns_set_active(struct cdns *cdns, u8 set_active) -{ return 0; } +static inline void cdns_set_active(struct cdns *cdns, u8 set_active) { } static inline int cdns_suspend(struct cdns *cdns) { return 0; } #endif /* CONFIG_PM_SLEEP */