From patchwork Mon Jul 19 14:50:27 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 479898 Delivered-To: patch@linaro.org Received: by 2002:a02:c94a:0:0:0:0:0 with SMTP id u10csp4226160jao; Mon, 19 Jul 2021 08:22:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjfzEVGl+cPqJzphTGsmV7xz23vG5UQybW+aLpuT/mmuRpLQLtDack6wxAh7wTCw1RiNVA X-Received: by 2002:a05:6402:2206:: with SMTP id cq6mr35245328edb.209.1626708133339; Mon, 19 Jul 2021 08:22:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626708133; cv=none; d=google.com; s=arc-20160816; b=in/vg9Y1dnIQpbZTl2Hn2RWAWwGkHlBUXfChHnBjRPOtKP9nLMdDLoFes2LzMDfwdt JSAcSqUngzNrGV2vBN6XsuiY1qVWJ9pdaxohdzgnpA9SbkFrZyC178ZiEfvjWH0hhOG+ F1eAverOw6NEuVoyMaWCLcGvNf1mNx2k+stoXjv1iSKeulR/6i9cYl66nCUDX/uKt2DE 4PBncJhQXFWWFWhVi3usEdxwBp8tVxcJLnruYOJR2sYUbETC6++kUa9ue2elo3mvRQWv a4kXwgFTn/wa9prt8SLw8LWGYWXTTFSXuYMd0poF+m4nVaaR8LNKXbe2HaF6uICWXtJO zYWw== 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=ZwPPrC1lMmOs0hHVAzSPgNjz6wHpnVVGGnHbO1lmFZo=; b=Q/TupyvGcIcdorKjnoQjXP1AKZ6E07yMg4rss1g9ByRIGhPw61I/gqBbb5N8UkrJCo swN31ptuyea+B4j/5PxnfIsVGSCMtlJZjlPQ158ARXWR/9ICYoPwl+sj1b9ioODz2sZ2 yy5C6ITG33ttltIvxXvxKyH+5xfeguXuMqn54axI7gHcvKE4R8phRVQdLKABrpaS6BBG Toko9gzWZhOBbv40Xpqie1bPOobPgApIqXV3FflqYpT4q8Q0MPdWJa9IKoYipnmqrfI+ pEsjuYYnKVBARThqKEDl9IImjjWh+RFNBk/t5MFiZoP9JofcKx7RNlY+gGlqHCqUYi5a go3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=TRa2csLC; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-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 l3si24719878ejo.634.2021.07.19.08.22.13; Mon, 19 Jul 2021 08:22:13 -0700 (PDT) Received-SPF: pass (google.com: domain of stable-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=TRa2csLC; spf=pass (google.com: domain of stable-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=stable-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 S244602AbhGSOk5 (ORCPT + 12 others); Mon, 19 Jul 2021 10:40:57 -0400 Received: from mail.kernel.org ([198.145.29.99]:54478 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343936AbhGSOjv (ORCPT ); Mon, 19 Jul 2021 10:39:51 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C945761002; Mon, 19 Jul 2021 15:19:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626707997; bh=rQGy8cqcvQFQWXICBxVU7vxBghpZ8ulbRgzAOF6P3BY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=TRa2csLCC8KsPJ1+RLRLCeJEp2eyx4b12DlwpzD6B1B3av07dTwruaaipLlHuBpA1 BzMc/qZtoJvYMo87krX1IJTgb5sCb5Cpb5paQ8isI75OB+ee1rSu4AseLXLH3IcOeK 2QVhi8elDJJrSeQ+uS2wiUxYQOSM4eCzQ0gCSciA= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Hulk Robot , Zhen Lei , Dmitry Torokhov , Sasha Levin Subject: [PATCH 4.14 138/315] Input: hil_kbd - fix error return code in hil_dev_connect() Date: Mon, 19 Jul 2021 16:50:27 +0200 Message-Id: <20210719144947.430578947@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210719144942.861561397@linuxfoundation.org> References: <20210719144942.861561397@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Zhen Lei [ Upstream commit d9b576917a1d0efa293801a264150a1b37691617 ] Return error code -EINVAL rather than '0' when the combo devices are not supported. Fixes: fa71c605c2bb ("Input: combine hil_kbd and hil_ptr drivers") Reported-by: Hulk Robot Signed-off-by: Zhen Lei Link: https://lore.kernel.org/r/20210515030053.6824-1-thunder.leizhen@huawei.com Signed-off-by: Dmitry Torokhov Signed-off-by: Sasha Levin --- drivers/input/keyboard/hil_kbd.c | 1 + 1 file changed, 1 insertion(+) -- 2.30.2 diff --git a/drivers/input/keyboard/hil_kbd.c b/drivers/input/keyboard/hil_kbd.c index bb29a7c9a1c0..54afb38601b9 100644 --- a/drivers/input/keyboard/hil_kbd.c +++ b/drivers/input/keyboard/hil_kbd.c @@ -512,6 +512,7 @@ static int hil_dev_connect(struct serio *serio, struct serio_driver *drv) HIL_IDD_NUM_AXES_PER_SET(*idd)) { printk(KERN_INFO PREFIX "combo devices are not supported.\n"); + error = -EINVAL; goto bail1; }