Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp1246241ybv; Thu, 6 Feb 2020 00:22:15 -0800 (PST) X-Google-Smtp-Source: APXvYqwdQjeH666YLbNQPP+vFW6XVsXXUzrm4Zy/q/Rlhc+0ACqeTzDdUPY075aNCpfXxNUiWRfW X-Received: by 2002:a9d:2028:: with SMTP id n37mr30650963ota.127.1580977335254; Thu, 06 Feb 2020 00:22:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1580977335; cv=none; d=google.com; s=arc-20160816; b=t1TKb8CLNu5wTjkP3/fsNY3CffQDJMqH32azUonRBn4j8P3i1LnnDmEYZ0l19odE9M uvh/STDp9AQEm3G4i9l+1CKYfDmP+D8AQYvNvk5Bpi0WxJobFGMQE3wb+A+y7y3wJ8/D ra6Wr5dx2H2/JnNeZudVlkXD7HkhA9fNO/Efpj5JW8PrSzWW3xZrIXstuDxdC4BF06HV RwE60LXjpjR25lryEzVoxQRtL+ypa16wqD69deo/ZxfKymRulgozVQOpsBayKzOdWTtg CTYu463hoPFwKcgH6S+CYRdAWHLjmTXJxngPEvTaq1KKrYUBJnWHUIkkm+8G0nvNDENU gu7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=pNqlj/aIPtqooHVrOVDSEY2d6+X7P8FExh0I8Cp7N+M=; b=XrKQF/jJlBiCxbUKGEaqHErUVirL+CIYVV0IE7Q9/7y2CVsU60D5heSG6MtIFV0sFK StIMgfz/vnq9+5EEOTivXH9k5bkTAojvXdvYlhYwJMJ0fyTwpPmAfGHoRoXCoW43Ya5p d7dibtkeYPwWTpxDJCwOFi7J6T5hPfOwnhFKKryMy4mnAXp/wqR+x5jICvNyt1pk7X3M t7PItMznRR7MnmjdoZLSsw1UaWbPBm28C1EWZ5y4O0yxRrVR5s8+u/1xJDebwxPbT/Ic AU1cOBTynQas6050GoRiySjZCO1sWjvESVi3ANt0rGe7vNi2UjTqdkSkJjafi6xkB1tx yayw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=McrXmcwk; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z3si1318288oib.164.2020.02.06.00.22.03; Thu, 06 Feb 2020 00:22:15 -0800 (PST) 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; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=McrXmcwk; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727864AbgBFIKM (ORCPT + 99 others); Thu, 6 Feb 2020 03:10:12 -0500 Received: from us-smtp-1.mimecast.com ([205.139.110.61]:22270 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727572AbgBFIKM (ORCPT ); Thu, 6 Feb 2020 03:10:12 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1580976611; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=pNqlj/aIPtqooHVrOVDSEY2d6+X7P8FExh0I8Cp7N+M=; b=McrXmcwkZxmBrf0fk2DjVFtKG+cuBOkHIo7R3HGeWWSn87eq70c43KlfbSDAqUwo9pRzfk w+QhRQ57pr6FGBSju0NeloVyAR8apBJfpZHjMp7fN1Q3KYNySxmnGjXDoSQ5XgG8sNb1Sl hwbSi9zsopiljoibR7oiGDbCPNgz4es= Received: from mail-qk1-f198.google.com (mail-qk1-f198.google.com [209.85.222.198]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-12-YJvyVyNaP3efqkA9Stcgzg-1; Thu, 06 Feb 2020 03:10:04 -0500 X-MC-Unique: YJvyVyNaP3efqkA9Stcgzg-1 Received: by mail-qk1-f198.google.com with SMTP id i135so3051965qke.14 for ; Thu, 06 Feb 2020 00:10:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=pNqlj/aIPtqooHVrOVDSEY2d6+X7P8FExh0I8Cp7N+M=; b=Hqw0Bj+4zArw5hbAay55NLjpKUMOjFVhXE1lSLIAFKbhRGg83gkPYnt4WsHP7cJGkK 691giLuuBQX20C37Knoq0JzY5eP1LRNjTA4j17vp8iXTm7cZjyn07nv0CKiytqD1u4SF k12p4nKgl62XwQYyaX63K++cQFGyMwsMcQrH44SmETDlhj4Zbu8nkjN9p+dVdkwx9e0U bWuvJtFW9ZGFTW9XghFtaLSzbOImm304RVEWJRREig+ED5+SUfP+fLhhIaLw01rE3nzT zOwXXrPTFsW2Zm0sWnZLw2PnxZD4Go5InWNx+6if9fzljw2BfKSYzop75A9PuOB3bS09 wxHg== X-Gm-Message-State: APjAAAUBCrvmjLArVEJKtws347Zz1K0PSbEYn8GqYfAoMwSI/zZNSxh+ wvIQ1y7GyBb7r+BP2yeTO/bb1q0kvoGPj3CWpYpWO8luHVyrAOm2CC74YSwAWeWNpxCl3UqtjpF l+R6T8OV4hfrpkh6NppbXFs+BBMzLrrncsn/7MsCK X-Received: by 2002:ae9:ef4b:: with SMTP id d72mr1392222qkg.27.1580976604405; Thu, 06 Feb 2020 00:10:04 -0800 (PST) X-Received: by 2002:ae9:ef4b:: with SMTP id d72mr1392204qkg.27.1580976604136; Thu, 06 Feb 2020 00:10:04 -0800 (PST) MIME-Version: 1.0 References: <20200126194513.6359-1-martyn@welchs.me.uk> In-Reply-To: From: Benjamin Tissoires Date: Thu, 6 Feb 2020 09:09:53 +0100 Message-ID: Subject: Re: [PATCH] HID: Sony: Add support for Gasia controllers To: Jiri Kosina Cc: Roderick Colenbrander , Martyn Welch , linux-input , lkml , "Conn O'Griofa" , "Colenbrander, Roelof" 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 Hi, On Mon, Feb 3, 2020 at 12:23 PM Jiri Kosina wrote: > > On Mon, 3 Feb 2020, Benjamin Tissoires wrote: > > > I am definitely not in favour of that :( > > > > The basic problem we have here is that some vendors are overriding your > > VID/PIDs, and this is nasty. And I do not see any reasons why you can't > > say: "well, we broke it, sorry, but we only support *our* devices, not > > third party ones". > > Well, it's not about "we broke it" in the first place, as far as I > can tell. > > Roderick's concern is that 3rd party devices with overriden VID/PID > malfunction for completely unrelated reason to (correctly working) changes > done in favor of stock Sony devices, but it'll be Sony receiving all the > reports/blame. After re-reading the code, I am not sure we can easily detect the clones. So at some point, I think we will break them, but there is not much we can do. I don't really have a solution for that :( > > > One thing that comes to my mind (probably not the best solution), is to > > taint the kernel if you are facing a non genuine product. We do that for > > nvidia, and basically, we can say: "well, supporting the nvidia blob is > > done on a best effort case, and see with them directly if you have an > > issue". Tainting the kernel is a little bit rough, but maybe adding an > > info message in the dmesg if you detect one of those can lead to a > > situation were we can count on you for supporting the official products, > > and you can get community support for the clones. > > Yeah; which I wouldn't like to do for upstream kernel, but Sony could > definitely do this for the products they ship. > > The same way distros are tainting their kernels when unsupported modules > (but otherwise perfectly fine wrt. GPL and everything else) are loaded > into distro-supported kernels. > > > One last thing. Roderick, I am not sure if I mentioned that or not, but > > I am heavily adding regression tests for HID in > > https://gitlab.freedesktop.org/libevdev/hid-tools/ > > ... and words can't express how thankful I am for that :) > OK, I played with that idea earlier this week: https://gitlab.freedesktop.org/libevdev/hid-tools/merge_requests/74 I only have a Sixaxis controller, and I only implemented the USB part of it (AFAICT). Currently this ensures the button mapping is correct, and that the LEDs are working properly. We are still missing a few bits and pieces, but the initialization (requests made by the kernel to start the device and press on the PS button) is handled properly. If this is something Roderick would be interested in, we can then try to extend this initial work on Bluetooth controllers and the DualShock ones. Adding the clones ones based on the current kernel code is something doable, but I do not expect Sony to be involved in that process. That being said, before we merge this particular patch about Gasia controllers, now we need to implement a regression test first :) Cheers, Benjamin