Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp2831132pxv; Mon, 12 Jul 2021 03:02:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwPhkl4uCoqfsaJbd7XEt+1Jx5SaIlRwfHQAz/MjSfkQQQVCBMK6kfYCSTvNz94UXn7xIti X-Received: by 2002:a6b:4905:: with SMTP id u5mr37463728iob.55.1626084126445; Mon, 12 Jul 2021 03:02:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626084126; cv=none; d=google.com; s=arc-20160816; b=JCYH0MqpcOsxidaVoa5TyE9CbG5Zm+Fyr2kx4My3QvQV4Jm8u8gwspfHWUthuYCcZv pjczq0RZD8ZLkSVAWrCiCXlscCsFFzMI2ILgVJclclMy2Le0814F0WY744njT/tINb8z U3JDU38QhvJezgbTIiPV46Hdps387u+qhps8f+SdKTBrtplX9INDDCleCTbJOtSXY0yz 1iO08xFtq0ct2qddp4BcjEWeW9bbVEO4Ti0cDOOqPl/dyS0EsaEL/pt4vzw46Ko8ywWF DZ/0E9b4KGGDNQ23PUDklxOqVGwRsw35iqSZyVvrxsPA83fpkBgF/42542w/7o00efKX gM+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=KyHbFicJogX53djhnjol6TV/1IJPGIhlGM4UxW5fVbA=; b=FUfnEDI4Gy/+ktn/Vc3zNENgFAGHq091tUxQXGqLTO+9y9v+2hKfnkTOjbiyKj90W4 P+X9iPpZe38soRgeoA/mFtLKaQ7hR8AoTqmWSBiMEK28LcQfV3MxtIRF3wi1rFT0mPUb js7wfEmfdUZyHBujzzwil4KP5+Qhta9uWuSgOyTi/b5aVBp+d880v5JG7VUiGcQ2xsmQ k5EeUlNHii1aotKDSJ23Ohx0F80UpN47cTYqcHlLq1D4LX8XTj7a4azODB4bDQBjecYm Os4wnBcCoVOimx6CnPQEQ8VuxWzr9oHy+K+H+OxYAilC6G5LK2fv62wltcetGMZ7PqyP IZPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Tx9LNGbk; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q4si7341983ils.118.2021.07.12.03.01.53; Mon, 12 Jul 2021 03:02:06 -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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Tx9LNGbk; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244975AbhGLHO2 (ORCPT + 99 others); Mon, 12 Jul 2021 03:14:28 -0400 Received: from mail.kernel.org ([198.145.29.99]:49610 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239463AbhGLGts (ORCPT ); Mon, 12 Jul 2021 02:49:48 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A8F8660FD8; Mon, 12 Jul 2021 06:47:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626072421; bh=pLyHru/6LPL5ZD8EdeUCxgMJ0rk2W/O2xl6joVuYubI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Tx9LNGbkbcTGr9xLNmBhJPHrD6nqB+kIzeJjfWQkJuEB+aGcmTgAkLvtPDV1t3kyD d0u+pJ7cAcxksmk3zAczUqdQgslJ/T1A3piVZkpYzDcW+BUS4wtLkfrN80xNNb5BBl TevHrViOk20BaYT/musPjYEj0d+ZSyN+hhzPX1+E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Eddie James , Joel Stanley , Sasha Levin Subject: [PATCH 5.10 491/593] fsi: occ: Dont accept response from un-initialized OCC Date: Mon, 12 Jul 2021 08:10:51 +0200 Message-Id: <20210712060945.296010908@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210712060843.180606720@linuxfoundation.org> References: <20210712060843.180606720@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eddie James [ Upstream commit 8a4659be08576141f47d47d94130eb148cb5f0df ] If the OCC is not initialized and responds as such, the driver should continue waiting for a valid response until the timeout expires. Signed-off-by: Eddie James Reviewed-by: Joel Stanley Fixes: 7ed98dddb764 ("fsi: Add On-Chip Controller (OCC) driver") Link: https://lore.kernel.org/r/20210209171235.20624-2-eajames@linux.ibm.com Signed-off-by: Joel Stanley Signed-off-by: Sasha Levin --- drivers/fsi/fsi-occ.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/fsi/fsi-occ.c b/drivers/fsi/fsi-occ.c index 9eeb856c8905..a691f9732a13 100644 --- a/drivers/fsi/fsi-occ.c +++ b/drivers/fsi/fsi-occ.c @@ -445,6 +445,7 @@ int fsi_occ_submit(struct device *dev, const void *request, size_t req_len, goto done; if (resp->return_status == OCC_RESP_CMD_IN_PRG || + resp->return_status == OCC_RESP_CRIT_INIT || resp->seq_no != seq_no) { rc = -ETIMEDOUT; -- 2.30.2