Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3853836pxv; Mon, 19 Jul 2021 10:18:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxmYdSePI8VP5Sb+mh0iZ4mQWpeiqHAhmqxbLL1+7/IfUmZvA1x6dk5v931bCjHod/W6a2L X-Received: by 2002:a05:6e02:f05:: with SMTP id x5mr17428141ilj.268.1626715089849; Mon, 19 Jul 2021 10:18:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626715089; cv=none; d=google.com; s=arc-20160816; b=P2ileBWtrSD58wp6qEgevZTCMLUWvG7yfOUABj0SOsQOX3esp0eTfAkLm0zZQFEngS XuhR/wXxP8ETBtSI4cK4yLVbSSPO+iutR3aorHewx311wki2Q35MkkO8ZXeSGXkVUSrl zmOYeG7D3TXjr2am6EvVtewcQ9ZBNekL0nXouoJcPoN6HywjY5bwgFESsldtbedVyTZ3 SgADhY94a2SCgh204gd5WegVrVB+1oUc4rI3/QV3fh11+PbFOXMfeS4U7vWV2VdyL1Yg OQCmAujnkOSzNoAxYvtKAIA6krYappSJij8e+A2410ajXosFlLdct5iHREjpPa6FWT5a kYVA== 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=1efOlS99/4BGkgJGKY1SRevcDVAK18PXCu3Cr8mVVyY=; b=AbPqZMTqPhnQAcdEPMkNRWV0WVIxffaUyvH8jKfZNTs4WZSShMPChNRbxWkQlJRtP+ yxVpYE5UtdYGgNaaKUHjV8Js+dAnoC+QOwMu39J2gZmWzhAjAxIGZkEy8Y9o37tDeiKB uecZHb2TJAyce1KOmtJm1JtsWPntYGs2qN7n97H5ZCEJk+lSSCPzbKJuOMMC0oYxInIr 88ar9bULADOPY3fssVT15qS029j9VRrFZj04AHeLc908v/04lsE+QmdcP1p7KZHs3R2e hxSGZnQ94duHEnNg7jIDJbv3Z6Lyr2xvCbw5ELibsc9kWOgUZr1cRv1GjeI46weQPXC6 r04Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=WeP3bCXr; 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 v19si10802892jat.76.2021.07.19.10.17.58; Mon, 19 Jul 2021 10:18:09 -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=WeP3bCXr; 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 S1352792AbhGSQeW (ORCPT + 99 others); Mon, 19 Jul 2021 12:34:22 -0400 Received: from mail.kernel.org ([198.145.29.99]:58334 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346962AbhGSPSZ (ORCPT ); Mon, 19 Jul 2021 11:18:25 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6F09A61402; Mon, 19 Jul 2021 15:58:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626710294; bh=UxX7E/3Wyq0jhAF9czvnldpvgqX6Mzs0NdJQVvqk8Rg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WeP3bCXrJOHlfAG1aR8ajTvWFaGCo1Hu9NU0qa/pxMQNNE3JKb8ASbHk8zuOOJBW1 3C41eEs07J0uOHUbsUqBh1KccnPz2KHPahlyPFx4mPRPqZ30QIlnzIL+T6hj/oSfOx UUm7S7bHQYsEUxguBng2doZ/4NytkjXaF9qRXp8g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Zhen Lei , anton.ivanov@cambridgegreys.com, Richard Weinberger , Sasha Levin Subject: [PATCH 5.10 157/243] um: fix error return code in slip_open() Date: Mon, 19 Jul 2021 16:53:06 +0200 Message-Id: <20210719144945.976221221@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210719144940.904087935@linuxfoundation.org> References: <20210719144940.904087935@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: Zhen Lei [ Upstream commit b77e81fbe5f5fb4ad9a61ec80f6d1e30b6da093a ] Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Fixes: a3c77c67a443 ("[PATCH] uml: slirp and slip driver cleanups and fixes") Reported-by: Hulk Robot Signed-off-by: Zhen Lei Acked-By: anton.ivanov@cambridgegreys.com Signed-off-by: Richard Weinberger Signed-off-by: Sasha Levin --- arch/um/drivers/slip_user.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/um/drivers/slip_user.c b/arch/um/drivers/slip_user.c index 482a19c5105c..7334019c9e60 100644 --- a/arch/um/drivers/slip_user.c +++ b/arch/um/drivers/slip_user.c @@ -145,7 +145,8 @@ static int slip_open(void *data) } sfd = err; - if (set_up_tty(sfd)) + err = set_up_tty(sfd); + if (err) goto out_close2; pri->slave = sfd; -- 2.30.2