From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ot1-f43.google.com (mail-ot1-f43.google.com [209.85.210.43]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C943533D4F5 for ; Fri, 10 Apr 2026 19:26:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.43 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775849167; cv=none; b=b3SOkdIEJ4admM7go3djkB0pv3rrirlEtnEFwd2ivDoeBSIGBgsM27JvpwAVAHDYxim3odOwRYz08MTAaKRyoJv14voztGvv7q8G3so17T+KTW4ijIY7Z78VoK8ZCE8BvMAu3XVQ/gCXOtaK9Q/8+DWkJWEz3OqNMZQzB4U0620= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1775849167; c=relaxed/simple; bh=s6wEwwesVR26iVgn/tsSt+twoNPoH8F2NzpaStGjxl0=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=j2P3dyihflAQ32tJW+WHwLyFSYXcg3qWauolwjvOTqhBD4RUhUbiof/J9arZ8OSrkuWr2LEPvH3mlbR9XfGJg2AZ9m+e8RM+MoOd9OQ1CYoHqdXdA4Eq7bDM+sJ5S/ISKQL0x6EhOfBgB+/r53zSG2zKoxAQE3ZHp5j1GTKrcK0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com; spf=pass smtp.mailfrom=baylibre.com; dkim=pass (2048-bit key) header.d=baylibre-com.20251104.gappssmtp.com header.i=@baylibre-com.20251104.gappssmtp.com header.b=btaVtpvR; arc=none smtp.client-ip=209.85.210.43 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=baylibre.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=baylibre-com.20251104.gappssmtp.com header.i=@baylibre-com.20251104.gappssmtp.com header.b="btaVtpvR" Received: by mail-ot1-f43.google.com with SMTP id 46e09a7af769-7d9b21d1461so2289000a34.1 for ; Fri, 10 Apr 2026 12:26:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20251104.gappssmtp.com; s=20251104; t=1775849165; x=1776453965; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=iKiBe8rgBpLHxLTkNsa5b/bSw+gXJRM0EijygM+CrR8=; b=btaVtpvRxz+asaplnw0u8J0cuCm5irmHOotU9PqcQ7yo+51RhUeCrOyD7Bg0aasLKp 5ICQm9SuxufAX0ArKH+zesAlQabUvbOKiv56k/mum6wUcluZldlru3gYqNxVjcWNqh2Q ygevjbKksPZP4Q0TdALKsAQNz64CQO4EujtCVlEBsmVc3eY54OOFNhgm4P8cEDnQQSzF BTGH/eWPP64A7f4OO5vIafl6UwJ8Gx7uaD7IzxeZ+/VhPR6IZATukDr+ald9I+r5HKHH I7DliDQCinwG6Sc1geMDsA8bn1bT/tSOu10sR1gWX0zM/HHZIiJhbAJYXCQ2672dNmJa 5yFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775849165; x=1776453965; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=iKiBe8rgBpLHxLTkNsa5b/bSw+gXJRM0EijygM+CrR8=; b=WkekIcLiZsqMtVy6olaer5EGNoyHxZXEQhwmBbC95jChGE3bG5yH2DR0G63kpXR7pA cyFp/0RUg1an3h5srnJwwLI57+VAnKsGBxOCxleMcNMqOt614Xmcs0HRLWIBNenYJqac vIBFGsux9mnRd6hQJzK2n2yQXyX30xHXP/60eIVNniqHsXKLykzVzEQ9SXU81l1Bh7pC FhStxIZ7ugtlRMUzDgqcTO83pvw2jRLIXQAsFs9+wSIzVSOHykDKywK7rts80sWMIHnR etviP15UxGQ1bCSgGHs2rMVnxAinveRBRpWce2MywbWDyyHI8J5PSPxdK43KWPFA1x2V 1RaA== X-Forwarded-Encrypted: i=1; AJvYcCX2Ter3lar7rqV1OTNoGDLaECNg4D1T4T4QILG4uGWymPAPCVda/X8AcdQknzQOL+0TkUrI5tZE7kT7arI=@vger.kernel.org X-Gm-Message-State: AOJu0YzbEV7gncp+TWboGlELuDlj4ByHjIKdRNzoUXuySMVf3KgRF6XQ dAC7sG3I/aOXqRVFRVOJ/dawDbIDbrVeoxd8SUTJLZtCYQ0NE+ezB3XS4T7AJe4f0ts= X-Gm-Gg: AeBDiev7qIF68wrvGvOAYo//cqI2qmBEmFKAZHXjSaSV7BVbnmO9GLftnBJ2XxBfsLQ CTitnpSpxcb6l9l3SQXrulwvdAJrAfg6ORjlxUxGTubsjN3OkvDu4T3+hMtPMfNq23D5KIJ/coJ KQbsj+olyYl45CjOPln1ZhCsIMfBFIcvl+g2evy+B5PDFB8yOmOMgU0B5sfRyvF6/gPAWnXfDT1 Qlr3NwDtO27iAKSUhl+Opy7kceG3J8T8KIwTh2vLB7CApyAg3CqkQwAcrbSE7rh9sZf21FjK9eT epd5lT/nOQxEdZz1gsK4jg+kwbW736zv7v4zu7SXBYhAwhXqNQa+WR65DazJmtE4YS6UCqrLK3t VIah+ABmUGu/cENol5JwZXW2Gqbq/TzuGJWR/Ck9CQJeDS9qWhUcF8bfPmqN0tgF0f5AVvQWSy3 HfELM0RyctVkZuW15I2tpX9kI3fUUS5llaz8QZ7bf6h3SLmn8lQ3ApUYb78XuchfiN+H4BoFBQs w== X-Received: by 2002:a9d:7b4b:0:b0:7db:a297:9e62 with SMTP id 46e09a7af769-7dc17632cfbmr3187099a34.8.1775849164720; Fri, 10 Apr 2026 12:26:04 -0700 (PDT) Received: from ?IPV6:2600:8803:e7e4:500:b75d:2440:dc10:808b? ([2600:8803:e7e4:500:b75d:2440:dc10:808b]) by smtp.gmail.com with ESMTPSA id 46e09a7af769-7dc2664157fsm2580273a34.12.2026.04.10.12.26.03 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 10 Apr 2026 12:26:04 -0700 (PDT) Message-ID: Date: Fri, 10 Apr 2026 14:26:03 -0500 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 0/4] Add QST QMC5883P magnetometer driver To: Hardik Phalet , Greg Kroah-Hartman Cc: Jonathan Cameron , =?UTF-8?Q?Nuno_S=C3=A1?= , Andy Shevchenko , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Brigham Campbell , Shuah Khan , linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-staging@lists.linux.dev References: <20260409210639.3197576-1-hardik.phalet@pm.me> Content-Language: en-US From: David Lechner In-Reply-To: <20260409210639.3197576-1-hardik.phalet@pm.me> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On 4/9/26 4:07 PM, Hardik Phalet wrote: For a series this be, please wait at least a week for more feedback before submitting the next revision. > This series adds initial Linux support for the QST QMC5883P, a 3-axis > anisotropic magneto-resistive (AMR) magnetometer with a 16-bit ADC that > communicates over I2C. To my knowledge there is no existing upstream > driver for this device. > > The driver supports: > - Raw magnetic field readings on X, Y, and Z axes > - Four selectable full-scale ranges (±2 G, ±8 G, ±12 G, ±30 G) > - Configurable output data rate (10, 50, 100, 200 Hz) > - Configurable oversampling ratio (1, 2, 4, 8) > - Configurable downsampling ratio (1, 2, 4, 8) via a custom sysfs What is the difference between oversampling and downsampling? I think we have used some filter attribute for downsampling/decimation in some other drivers so maybe that could be a good fit? > attribute > - Runtime PM with a 2 s autosuspend delay > - System suspend/resume via pm_runtime_force_suspend/resume > > Regmap with an rbtree cache is used throughout. CTRL_1 and CTRL_2 > bit fields are accessed via regmap_field to avoid read-modify-write > races. The STATUS register is marked precious so regmap never reads > it speculatively and clears the DRDY/OVFL bits unexpectedly. > > The init sequence on probe is: soft reset → wait 1 ms → deassert > reset → configure SET/RESET control → apply default ODR/OSR/DSR/RNG > → enter normal mode. This ordering was determined empirically on > hardware to produce reliable, non-zero axis readings. > > The driver is placed under drivers/staging/iio/magnetometer/ with a > TODO file tracking the remaining work before it can graduate: > - Triggered buffer support (iio_triggered_buffer_setup) > - DRDY interrupt support > - Self-test implementation These are not reasons to have the driver in staging. It is fine to have a driver that doesn't implement all functionality. We should be able to add those features without breaking anything.