Received: by 10.213.65.68 with SMTP id h4csp1537318imn; Mon, 19 Mar 2018 06:56:52 -0700 (PDT) X-Google-Smtp-Source: AG47ELuGgbRzHmEQ/s5teVDHoWSekfFAd+sBcezyJZmc0DmpBDJFcELr1mloqGI/xxDOPP8rm5Kw X-Received: by 10.98.150.82 with SMTP id c79mr10343042pfe.88.1521467812282; Mon, 19 Mar 2018 06:56:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521467812; cv=none; d=google.com; s=arc-20160816; b=TKbRxHWB7l40gbuokI6VBK1qKXZ62tcgUZrPICEsD2668IFe28D0QZMM4ncxiNUn2q FgiWr6kCcozRI88tMee1ENqZ8YbczhIcR4dF4rhXHMMertxb1Fyfi0SUR3khAFNRa/ck v6zsEc1tIje6d1jwoD/Mb+EmxEML/bb0OU4FZlAtVGQZI18IvW8V7pBlB/bSZ2r7b2Zd 0f/UwYN8J5bolp/uUVDWj0cClFL/fBK4u79smsUZjIerSlGNJx9PW/Ne5iAfDKzgrogr bF2clDnmrw2DjRDC808iAu3vwN+unFlb2R2WIJd13HggJJ/9rRJUIQr8J91shk+V1ToF f1nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=a7IOpzZw6/7yEyXRAOTavwL8UN9+uNF0HfI5H3QZQgs=; b=0/asJN05fzLv2gnyKoozExXU79N8sQTxRegllpEV5qLhNbftocX5ERqp1aOv2VDBap vpOVH4KqEtzesS84Jn4ICglS2OJg9eV0HUegnMvG5MF8YcNCFPMGDGejykRpaF8FfUXh 7A5PmpgZAMBMtIzWwTm8hiC9DFZu9HTqI6T+BRqbvrbMdBg58To1MH+KYAcR6++05V/z i453lcoz6D5olCLdwkz2QUf+sB/1/LY6xXCAv3bnnt+sfUw0L3XEz85eakbV47e1Zy9g XrTfzt7OdghrABkCQGhUmY2hUt2mPE06+SN2RgYdywpY7/GNjmiiXIagyXFZW8yaza/c EU+w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b=Xxv4svnO; 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 3-v6si26430pla.678.2018.03.19.06.56.38; Mon, 19 Mar 2018 06:56:52 -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; dkim=fail header.i=@gmail.com header.s=20161025 header.b=Xxv4svnO; 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 S933514AbeCSNyb (ORCPT + 99 others); Mon, 19 Mar 2018 09:54:31 -0400 Received: from mail-lf0-f47.google.com ([209.85.215.47]:44844 "EHLO mail-lf0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932949AbeCSNyW (ORCPT ); Mon, 19 Mar 2018 09:54:22 -0400 Received: by mail-lf0-f47.google.com with SMTP id g203-v6so11099109lfg.11; Mon, 19 Mar 2018 06:54:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=a7IOpzZw6/7yEyXRAOTavwL8UN9+uNF0HfI5H3QZQgs=; b=Xxv4svnO69RoalM/julzmk6flecoTGAnEg47/BqY/Ig0EhpJB6yaYh/Q2harC2vE4e IIZ/L95HhaNmMa0Tz4aVTEaUrV/6AMoTmCBRyTdXem8yAGqJi6Ccu790SCzh9uq3TehF goc95itO7EzfvvZBhhohvmXzId2QmMTjTmhCFCjXNsmECXVaqBm226PgykelOg+9l913 OTzRh3E3JLmaeOTAiVRmItnZ68cVHAXwY4zXRyXA/Yct+wTpt7y360DhJN5PCwJ3uxUM Y9JldKcszcXNaD8MAcTNjHWwrSwL/G5NJcGmDBcMb8Di9P3FKiZEdWSShazUiTiZXA7x 8Uuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=a7IOpzZw6/7yEyXRAOTavwL8UN9+uNF0HfI5H3QZQgs=; b=q7LKyY+ND9eAT6tYl56fTouJCVImX2WRWDfwojSHeuhxiMR6R+ckf0+yo0IpSVStxk +cHJIbHx9bri0YWZ346yWklnHJmp7beSLTY+MnaMY5tmdVc0GbXyL0IZe+z62GSNV8M/ 7gIdYY8zWyr9QtLEnxf54JpfuGrT2saIsXAAQLuHdMniwD+a2Hoy3EUdwvRdODRdGCAD Iv6cy4LaaBaHonqgQ+qF12RmmdlP+JSM0K7/sR+HXplJ+idcak+hMMekuZImvGDD/8rx 05Rz6dckRxfURMjm07f7T0g22QQZiYbQ9sWe1+jR7cXsGIyMLyuYqc6a2+Shbm3uotWw Js3A== X-Gm-Message-State: AElRT7F+TkNj/CjuPSEST7m7/B5TEt5RJESmBflFne6eQsAspHO2q/x4 AbaJriFY8vDUkFfQqOe/kE0= X-Received: by 2002:a19:1586:: with SMTP id 6-v6mr8661019lfv.17.1521467660294; Mon, 19 Mar 2018 06:54:20 -0700 (PDT) Received: from xi.terra (c-8bb2e655.07-184-6d6c6d4.cust.bredbandsbolaget.se. [85.230.178.139]) by smtp.gmail.com with ESMTPSA id g7sm15532ljj.50.2018.03.19.06.54.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Mar 2018 06:54:19 -0700 (PDT) Received: from johan by xi.terra with local (Exim 4.90_1) (envelope-from ) id 1exvEw-0002ln-Ew; Mon, 19 Mar 2018 14:54:18 +0100 Date: Mon, 19 Mar 2018 14:54:18 +0100 From: Johan Hovold To: "H. Nikolaus Schaller" Cc: Johan Hovold , Mark Rutland , DTML , Discussions about the Letux Kernel , =?iso-8859-1?Q?Beno=EEt?= Cousson , Arnd Bergmann , Tony Lindgren , Greg Kroah-Hartman , kernel@pyra-handheld.com, Russell King , Linux Kernel Mailing List , linux-omap , Rob Herring , Linux ARM , Pavel Machek , Kevin Hilman , Thierry Reding , Andreas =?iso-8859-1?Q?F=E4rber?= , Jonathan Cameron Subject: Re: [Letux-kernel] [PATCH v5 3/5] misc serdev: Add w2sg0004 (gps receiver) power control driver Message-ID: <20180319135418.GL18359@localhost> References: <5494ad34b39a6c62601e3747440268dfb3be7d5a.1512114576.git.hns@goldelico.com> <20171222124427.GI3374@localhost> <91850CC3-B280-4701-9D07-96AFF3A79A6F@goldelico.com> <90F9A8E4-035A-4A9E-8AAB-757491D63E69@goldelico.com> <20180112153903.GB5992@localhost> <20180212152618.GC13962@amd> <20180227070415.GB18666@localhost> <22A8F5FE-C8B9-46EB-B98D-A94EA4170131@goldelico.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <22A8F5FE-C8B9-46EB-B98D-A94EA4170131@goldelico.com> User-Agent: Mutt/1.7.2 (2016-11-26) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 27, 2018 at 08:32:50AM +0100, H. Nikolaus Schaller wrote: > Hi Johan, > > > Am 27.02.2018 um 08:04 schrieb Johan Hovold : > > > > On Mon, Feb 12, 2018 at 04:26:18PM +0100, Pavel Machek wrote: > >> Hi! > >> > >>>> Let's restart this discussion and focus on the main roadblock (others > >>>> are minor details which can be sorted out later). > >>>> > >>>> If it feels like a hack, the key issue seems to me to be the choice of > >>>> the API to present the GPS data to user space. Right? > >>> > >>> Or even more fundamentally, does this belong in the kernel at all? > >> > >> Yes, it does. > > Thanks, Pavel for supporting our view. > > > > > But not necessarily in its current form. > > Is this a "yes after some code fixes"? No, we need some kind of at least rudimentary gps framework even if we allow for a raw (NMEA) interface for the time being (possibly indefinitely). > Pavel mentioned an example where such an evolutionary approach was taken. > > > >>> Now, if we'd ever have a proper GPS framework that handled everything in > >>> kernel space (i.e. no more gpsd) then we would be able to write kernel > >>> drivers that also take care of PM. But perhaps that's unlikely to ever > >>> be realised given the state of things (proprietary protocols, numerous > >>> quirky implementations, etc). > >> > >> That is what needs to happen. > >> > >>> The kernel is probably not the place to be working around issues like > >>> that, even if serdev at least allows for such hacks to be fairly > >>> isolated in drivers (unlike some of the earlier proposals touching core > >>> code). > >> > >> Oh, kernel is indeed right place to provide hardware abstraction -- > >> and that includes bug workarounds. > > > > Right, at least when such hacks can be confined to a driver and not be > > spread all over the place. > > It seems that you forgot that the driver we propose is not spread all over > the place. It *is* confined to a single driver thanks to the serdev api. I believe that's what I wrote above. Johan