From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751148AbdJBIfU (ORCPT ); Mon, 2 Oct 2017 04:35:20 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:38518 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750763AbdJBIfT (ORCPT ); Mon, 2 Oct 2017 04:35:19 -0400 Subject: Re: [PATCH] powernv: Add OCC driver to mmap sensor area From: Benjamin Herrenschmidt Reply-To: benh@au1.ibm.com To: Stewart Smith , Shilpasri G Bhat , mpe@ellerman.id.au Cc: ego@linux.vnet.ibm.com, linux-kernel@vger.kernel.org, paulus@samba.org, linuxppc-dev@lists.ozlabs.org, akshay.adiga@linux.vnet.ibm.com Date: Mon, 02 Oct 2017 10:35:02 +0200 In-Reply-To: <87bmlqutq5.fsf@linux.vnet.ibm.com> References: <1506667651-32301-1-git-send-email-shilpa.bhat@linux.vnet.ibm.com> <87bmlqutq5.fsf@linux.vnet.ibm.com> Organization: IBM Australia Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.24.5 (3.24.5-1.fc26) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable x-cbid: 17100208-0008-0000-0000-000001592280 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17100208-0009-0000-0000-0000098EDFA7 Message-Id: <1506933302.25065.3.camel@au1.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-10-02_01:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1707230000 definitions=main-1710020123 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2017-10-02 at 14:14 +1100, Stewart Smith wrote: > Shilpasri G Bhat writes: > > This driver provides interface to mmap the OCC sensor area > > to userspace to parse and read OCC inband sensors. > > Why? > > Is this for debug? If so, the existing exports interface should be used. > > If there's actual sensors, we already have two ways of exposing sensors > to Linux: the OPAL_SENSOR API and the IMC API. > > Why this method and not use the existing ones? More than that, a sensor should be exposed to userspace via hwmon, not some random direct userspace map. Ben.