Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp2994137imm; Sun, 1 Jul 2018 09:55:58 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdeiqP0k1iqOopcUjsdot0y1JP70yepRCHOFLCZBnOWl0ZqtxQRWkRDsFCx9iq/AHIKJuKr X-Received: by 2002:a62:9bc5:: with SMTP id e66-v6mr22037093pfk.84.1530464158831; Sun, 01 Jul 2018 09:55:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530464158; cv=none; d=google.com; s=arc-20160816; b=laakiQ24UnQjTEO6TpxQT20g8vWyeQjoGZtymFoB3KD9t2BnauSPBW7zJbPcUDGAN1 lTPsex0wYZ/o+1Bmzsm5K/fAcqO6auQ3KfIEry/pwjC+j79Zmv1xO6jXd4m3uDslP09m p+w9j1fVfpxJc1H1O/HtbAkfDayOBfHTCg/8kw7gwq3UjeWUUHKUXTB4FG6hbFq0M8NV BAqzVqVD0BUi/DD4MK/lZQz/KC/ujj125Q93Nzzk9aSv5WbkDrrYblCzfb247UASS9jB lWoTyEH7m0ipVPyc60Rip0DWd3H61KR+nr6gqLldHTi9YYli/tbFS8uSkCMWNVe+5/c4 MEZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=J6DY/dYye2RfwJ1vBlwj7+h1Vw68Bkll4+9xUtPbR+E=; b=bY9zm8OgTUfGR+TBrcxI4Byj4vY/V/IhJNZRDp7kqbzn9LW3qNFp5+x+ZcU6vxeP80 NdIULcHHwxpxZnU5jt44ICLoFABRo2jVvjEv2t70hsiEB1A6fGRkYdSX6CqMQ2P54YWj UHSAtagnYYLbV90gz54xHs6kK6Tq7kae5u9bL2uem2hrWXWvtJqNax2oecPvqeIBZ6MI RGxoIOWzpVai39X2DIF8lkuo0R79SV2NfRO37yzG/27/XJkjEtHnVIZ+CrVItQbgvM86 EZ/rd9+WoxWw30GbDlwf5TtRke6b7iCR54f6YUgnjlVaGvlDn3/rHWQcGnudWHbsivQ7 ykyg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a95-v6si14162732pla.401.2018.07.01.09.55.44; Sun, 01 Jul 2018 09:55:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753700AbeGAQpf (ORCPT + 99 others); Sun, 1 Jul 2018 12:45:35 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:38232 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934137AbeGAQpb (ORCPT ); Sun, 1 Jul 2018 12:45:31 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 00335A73; Sun, 1 Jul 2018 16:45:30 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Enno Boland , Dmitry Torokhov Subject: [PATCH 4.17 196/220] Input: xpad - fix GPD Win 2 controller name Date: Sun, 1 Jul 2018 18:23:40 +0200 Message-Id: <20180701160916.373991151@linuxfoundation.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180701160908.272447118@linuxfoundation.org> References: <20180701160908.272447118@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.17-stable review patch. If anyone has any objections, please let me know. ------------------ From: Enno Boland commit dd6bee81c942c0ea01030da9356026afb88f9d18 upstream. This fixes using the controller with SDL2. SDL2 has a naive algorithm to apply the correct settings to a controller. For X-Box compatible controllers it expects that the controller name contains a variation of a 'XBOX'-string. This patch changes the identifier to contain "X-Box" as substring. Tested with Steam and C-Dogs-SDL which both detect the controller properly after adding this patch. Fixes: c1ba08390a8b ("Input: xpad - add GPD Win 2 Controller USB IDs") Cc: stable@vger.kernel.org Signed-off-by: Enno Boland Signed-off-by: Dmitry Torokhov Signed-off-by: Greg Kroah-Hartman --- drivers/input/joystick/xpad.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/input/joystick/xpad.c +++ b/drivers/input/joystick/xpad.c @@ -123,7 +123,7 @@ static const struct xpad_device { u8 mapping; u8 xtype; } xpad_device[] = { - { 0x0079, 0x18d4, "GPD Win 2 Controller", 0, XTYPE_XBOX360 }, + { 0x0079, 0x18d4, "GPD Win 2 X-Box Controller", 0, XTYPE_XBOX360 }, { 0x044f, 0x0f00, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f03, "Thrustmaster Wheel", 0, XTYPE_XBOX }, { 0x044f, 0x0f07, "Thrustmaster, Inc. Controller", 0, XTYPE_XBOX },