From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 30FFEA04A6 for ; Wed, 19 Jan 2022 11:45:37 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1E29241143; Wed, 19 Jan 2022 11:45:37 +0100 (CET) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id ECC084013F; Wed, 19 Jan 2022 11:45:33 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1642589134; x=1674125134; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=Ay8jmvdt9rMEdxpLCvmUlp6Yrr6hyLmHPd9suT6rtqM=; b=KuesyMxcemRep0oko0Dr8kd5xuMuW9vlrzqo7sm75OqQzQX+q3ym7Kh1 35PyT4wMU0nk2xgynU7FCfe0Yw9D8FWoPG2VEnOdEYf61P4WQd1HIGS8q zord68W1YatxBTYR2ULtIRX3hjtCQ40RT+dSfbCx/0D8piH5Ad3d9UN4q 0kyzAsT4eV82vEdNgbuTFFRfgZEF4q/hoyS7gIQi13hNmwCjGBpTUgAjg l8b2hksy8Aa25Fzo0UC0MaCokZcVb9oxrJ1vG9WFSJCaTmdq6xWapGWmc T7VArr7IoghufGdyFZCVgJ5XTiwnxsIT3S/MgBadai8D2Y3PRik3kgzih g==; X-IronPort-AV: E=McAfee;i="6200,9189,10231"; a="232402086" X-IronPort-AV: E=Sophos;i="5.88,299,1635231600"; d="scan'208";a="232402086" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Jan 2022 02:45:32 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,299,1635231600"; d="scan'208";a="595355885" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by fmsmga004.fm.intel.com with ESMTP; 19 Jan 2022 02:45:30 -0800 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Wed, 19 Jan 2022 02:45:24 -0800 Received: from orsmsx603.amr.corp.intel.com (10.22.229.16) by ORSMSX607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20; Wed, 19 Jan 2022 02:45:23 -0800 Received: from orsedg603.ED.cps.intel.com (10.7.248.4) by orsmsx603.amr.corp.intel.com (10.22.229.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.20 via Frontend Transport; Wed, 19 Jan 2022 02:45:23 -0800 Received: from NAM04-BN8-obe.outbound.protection.outlook.com (104.47.74.43) by edgegateway.intel.com (134.134.137.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.20; Wed, 19 Jan 2022 02:45:21 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=GMYQMaoHZd320hvvaQlTTI7pgZ+fxzbk4Y0jztEPfsBQsP29Qkto5K7DSl6PgXmVBYGC+esaJrq/qekd9ZJG/xhJ9P9Xzi1iScjjuqbaCELIyaV1J+MBWMSZKHKxdA9EVXoCYOcALmRKLNV9w6akyUMHBR45C/lwgifRtJyvrxrpRnAPBfIUUlFQYa+WxGRtShoUT8egDYy0eMI2J53+plTvQoaoeYaI+gH50ZKMxzSsWLHdoCZ6WVfbA9LExbYQ2dfryPZNDwCGZPTtOwkRrzwwF5KDsRdsuJt2PWLVESp12pmo4y65a+0a30TQ1twLf2nd1PZYN9gUW7xUfLh9Iw== 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=nd6PXUYVEVrXFj8gVRyDzEBhR3tV3txbT0zvp+b2ZUs=; b=G+OAjFnAplPFVxoZD7jScIyY58XCg3exLO1RAHgmi71+1tl8iCVH1rfIhni2ELPG7aIU24Y+N2qYuYq+GNY0rpa2vtDeTdJIFAZa/HV+CTDSvyKAfPzZ+4NM0xP9WgYpbMJqbG0WDxwncVytM+f7DDI+/gPYpDfaCUFyvY5Zk+1je0qBeqwWL6WlHj7/PcAuYd8r6lkha5l9zc7xFRGh/6GJJ+rYLVt0IhQ4wJeOnxxGURTecHsQlzhvCVv48f2s/C6S2wZs0tqkTkV3obCJq8l0/xAvbfHiqI1Gj75vUAx3ikGr1a+O1H9DHxgj6TDo2jH8k+egRSDiko+UtvSlvw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none Received: from DM6PR11MB4252.namprd11.prod.outlook.com (2603:10b6:5:201::26) by DM6PR11MB4089.namprd11.prod.outlook.com (2603:10b6:5:198::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4909.7; Wed, 19 Jan 2022 10:45:18 +0000 Received: from DM6PR11MB4252.namprd11.prod.outlook.com ([fe80::e0a3:bb14:9df1:70d4]) by DM6PR11MB4252.namprd11.prod.outlook.com ([fe80::e0a3:bb14:9df1:70d4%4]) with mapi id 15.20.4888.014; Wed, 19 Jan 2022 10:45:18 +0000 From: "Xu, Rosen" To: "Huang, Wei" , "dev@dpdk.org" , "Zhang, Qi Z" CC: "stable@dpdk.org" , "Zhang, Tianfei" , "Yigit, Ferruh" Subject: RE: [PATCH v1] raw/ifpga: fix pthread cannot join Thread-Topic: [PATCH v1] raw/ifpga: fix pthread cannot join Thread-Index: AQHYDPl0XbnIpckmwka/fknnnhdLf6xqKSbA Date: Wed, 19 Jan 2022 10:45:18 +0000 Message-ID: References: <20220119055415.4424-1-wei.huang@intel.com> In-Reply-To: <20220119055415.4424-1-wei.huang@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYTY0ODYxYWUtYTAwYi00MDNjLWEwMjYtZDRmYTdlMmE3NWVlIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiVWlSYllOMWNEK3RZSHVGNk5CelJBUkJXcUVjXC9WQzJqNEp3YlVVYkJycko4dXpwZVJVUWVPVnJSUE9OM1ZHRFYifQ== x-ctpclassification: CTP_NT authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1029a148-c049-4b65-2f2d-08d9db38c8d7 x-ms-traffictypediagnostic: DM6PR11MB4089:EE_ x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:6108; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: ReGnrtYz1dw8lxToXOippi3Qc0vYNmaBzl7ucTn1OF0XYOghGa5NxkBdBGshKKnpaD44ZM6Ty1A4CN2dC2m/i+xb56ungGNZj0GDBQNc9l8dJE/y33IDEeMpThEb3A941g6MYodywihHmNQyhbcrpjV/E8voplIflKJlDmdE0GJX62CNHpZEdogN87oPRBQKQEe/PBjF5fOVm645xAKdG/GLmQvj44DlueVMJP38zWLaodW3dan2d0Zfb/x9PoqsiBDj8MCqNgQwJwKqSfi4b0AqjE7Yk5D18/+bUUSgskg1NfQ2qJW3yXoQ5C0yBsddqUM9OBpUKwuoE/Dsmg8hl0SJzI7PoUIczFKs4C2RVFleTdncBW/Z1p2VmeBZDcz199g5tEj+UnoqLQV60Ffx6952i14793GKr/zgEqA9DqaiBa6tZ/SHVR8d+2yYmoYrvi9+gRcNkTdLOPxF2ObTiduw7a7bocYEg8rSDztkjLl4X4Qzyx83Vss/Gd1cqw/Tu6PD9YzYvUkgnL7QQPibB49qldfdBeFoIgzR+/qtWLKvnv2K20/dcKt/VdAN0Snh5gMk198O3eWpCDKuicfEuSICF3PhdLwT9a7fk0mFqR/T9nziq+4NHtlRXv5Jzng52mrb2PLwM567FKee2M109HB76LZ/9rjzaUj5b6KskLQhczWC2Hb9TIW9GuCGp9RQT072r84k3pkMwFf7ezOsmQ== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR11MB4252.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(83380400001)(508600001)(66946007)(52536014)(64756008)(66446008)(66556008)(2906002)(76116006)(66476007)(8936002)(55016003)(71200400001)(186003)(82960400001)(38070700005)(5660300002)(86362001)(26005)(7696005)(8676002)(54906003)(110136005)(38100700002)(9686003)(6636002)(450100002)(33656002)(107886003)(122000001)(6506007)(316002)(53546011)(4326008); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?RfrVKTSx+2d9dEox97zbNsA2KGSlO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h?= =?us-ascii?Q?IglYkIAIvGqnao/+RnOPd53kW/MvQm+zUAP/O+7KSlvSH9l6Yp9H22aSHrzL?= =?us-ascii?Q?lTyUS7fEVA9XamOUBW4gnpha4wdqpvkiZiCL0MUKMj1rUyOg12IhlwZAooFT?= =?us-ascii?Q?UWB9629/98Ru0wXXt5HlEP9HzVJ8SHL9Ok0PKu0RxeYSjkA5supSuHEBtg5x?= =?us-ascii?Q?cF8gAJYTHNwkHmO3JbMzfAsl1EQgcIZXLovO81Cg3gOlTCRG99iFOXczVhzB?= =?us-ascii?Q?Q7Y7iAXQeR91ojzffKw1aiCDn3cjmPFvubNWq1xwgIlinuoNGET8Im7YLsNf?= =?us-ascii?Q?Fry8t5kGWwOaKEfQIfNdDqxiRl4Bq0PoDAI5sgYOjqpDg3Zdz/DVw1Qk6QMF?= =?us-ascii?Q?11J3FpYqm8nORZh8gzgv03L0NZxZeGlekDUxmB9hx5PNPv1ofM7aCu8e6h45?= =?us-ascii?Q?c0o+iR5KpwoVwPVqCk8zVPAU1UaEuuDG7jQaBKcfO9Ji/YpLP8/HyT5anVzG?= =?us-ascii?Q?+bmUVO65yP/pv0otXy+fwXuyFIM6aAvTkM85R67k3k8VA1DDQZYWYkSGpMwb?= =?us-ascii?Q?VaDawoNb7oAWnYgOqNlW3V+PSNX53i12BVcqrN9AyChXTa9p/jh1yVtZbqOA?= =?us-ascii?Q?23HEET/XPUxxK5uZ/InMCUO3Iu/OfWj5UML/ed5lFOhOqzsyqGaq4jf/jA6X?= =?us-ascii?Q?tZZ2KGgtu7dFYq+eLafh7nAZBi2EWz/WRoTBGm1YP4zGL+Pmfj4Az8GkeObU?= =?us-ascii?Q?eQ=3D=3D?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM6PR11MB4252.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1029a148-c049-4b65-2f2d-08d9db38c8d7 X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Jan 2022 10:45:18.3207 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: TlOb6sTI4Eu9NFuOUdtZXQ5HLB0bL9m7ywCzI5QXdP23iy1s3zvTVX/zlNMsXceTqXNs2FsnE6iVNk9S3keb1Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR11MB4089 X-OriginatorOrg: intel.com X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi Wei, Some ci/iol-intel-Functional issues, pls check. Thanks a lot. > -----Original Message----- > From: Huang, Wei > Sent: Wednesday, January 19, 2022 13:54 > To: dev@dpdk.org; Xu, Rosen ; Zhang, Qi Z > > Cc: stable@dpdk.org; Zhang, Tianfei ; Yigit, Fer= ruh > > Subject: [PATCH v1] raw/ifpga: fix pthread cannot join >=20 > From: Tianfei Zhang >=20 > When we want to close a thread, we should set a flag to thread handler > function. >=20 > Fixes: 9c006c45 ("raw/ifpga: scan PCIe BDF device tree") > Cc: stable@dpdk.org >=20 > Signed-off-by: Tianfei Zhang > --- > drivers/raw/ifpga/ifpga_rawdev.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) >=20 > diff --git a/drivers/raw/ifpga/ifpga_rawdev.c > b/drivers/raw/ifpga/ifpga_rawdev.c > index 8d9db58..9663b67 100644 > --- a/drivers/raw/ifpga/ifpga_rawdev.c > +++ b/drivers/raw/ifpga/ifpga_rawdev.c > @@ -497,7 +497,7 @@ static int set_surprise_link_check_aer( > int gsd_enable, ret; > #define MS 1000 >=20 > - while (1) { > + while (ifpga_monitor_start) { > gsd_enable =3D 0; > for (i =3D 0; i < IFPGA_RAWDEV_NUM; i++) { > ifpga_rdev =3D &ifpga_rawdevices[i]; > @@ -544,7 +544,9 @@ static int set_surprise_link_check_aer( { > int ret; >=20 > - if (ifpga_monitor_start =3D=3D 1) { > + if (ifpga_monitor_start =3D=3D 1 && ifpga_monitor_start_thread) { > + ifpga_monitor_start =3D 0; > + > ret =3D pthread_cancel(ifpga_monitor_start_thread); > if (ret) > IFPGA_RAWDEV_PMD_ERR("Can't cancel the > thread"); @@ -553,8 +555,6 @@ static int set_surprise_link_check_aer( > if (ret) > IFPGA_RAWDEV_PMD_ERR("Can't join the thread"); >=20 > - ifpga_monitor_start =3D 0; > - > return ret; > } >=20 > -- > 1.8.3.1