Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1649824imm; Wed, 16 May 2018 00:40:11 -0700 (PDT) X-Google-Smtp-Source: AB8JxZprh0pl5uBjJuIXihC9k6ZauPlFRFMj+Q7rWbERrfVcar9dhdgLdkCv7QjUF7NV3u8M45xF X-Received: by 2002:a17:902:6045:: with SMTP id a5-v6mr17911613plt.138.1526456411403; Wed, 16 May 2018 00:40:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526456411; cv=none; d=google.com; s=arc-20160816; b=xxccFshR4r8Im20kVZvVXMQMi2G9ZnrWhX3bcWnicUQWCvG4p8hl2NczXQCqL/P0cq y08O5/iMTV7j07d5A5iSVg8kp5FtZRnISvnK4p8eOFsbnzDX1Mq1Wmp7rQiBBxn6dP3I M+wcqG4q31wvLwdxLgqwmqrwIlB+40NYla6Wx1R+wWR5FLWw4G3Rh2Hg7mB/HNaZgL6+ d0gK1jg3YgIPGe3yryPmoVd22SQw9x/CHwOh0BFQ7DdKHGweQEAjdLug9JFSlZbufNRM WH0I737uRUpsN95lJ7oo0GofMtdH5vlatFatE5rPVe6GN91C2unp4vKkIe4O+BnZVIBS 1WFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from:arc-authentication-results; bh=TLmR0gOJT4dbealsD/3Ag/Un5AFl4A2JWyf6CAExFps=; b=FpTESM6NaVXtaIzbucaaC3cmY9UMnfHXFwYsmJEfUPpS1mdkwAbVvkS6Ro14ZNcu7b iwl7Ktr7/97fZaqNwZxkjflYgaCy8XzrNBfn+p2w72eJ53zqSYKfvSY29BNlrVVb1bU3 jC1TnHQuA6CsJyZh7liOfMkPQi/25Uprqrwls1hOYgVxW6N3MR1d91wAsDb6a1pIXpvb cOJQo7WQb/wOIgshwtI6Hm7AdP4i+m8jOEjysK+wWs/TH5c/R6PZb98mqIFFwjvPGZWY W0Dsjcd0rGRUZZUYUifon69awXwNi9K1w5ucy8nWS2WDzPtvFcmXKW7tnsD+H+UOCUB7 uEOw== 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 h12-v6si1964553pls.278.2018.05.16.00.39.57; Wed, 16 May 2018 00:40:11 -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 S1752700AbeEPHh5 (ORCPT + 99 others); Wed, 16 May 2018 03:37:57 -0400 Received: from mx07-00178001.pphosted.com ([62.209.51.94]:19437 "EHLO mx07-00178001.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752129AbeEPHgs (ORCPT ); Wed, 16 May 2018 03:36:48 -0400 Received: from pps.filterd (m0046037.ppops.net [127.0.0.1]) by mx07-.pphosted.com (8.16.0.21/8.16.0.21) with SMTP id w4G7YTqw027306; Wed, 16 May 2018 09:36:13 +0200 Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 2hystn6jax-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 16 May 2018 09:36:13 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 71FCF41; Wed, 16 May 2018 07:36:12 +0000 (GMT) Received: from Webmail-eu.st.com (sfhdag5node3.st.com [10.75.127.15]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 1D5B015C2; Wed, 16 May 2018 07:36:12 +0000 (GMT) Received: from localhost (10.75.127.44) by SFHDAG5NODE3.st.com (10.75.127.15) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Wed, 16 May 2018 09:36:11 +0200 From: Fabrice Gasnier To: , CC: , , , , , , , , , , , Subject: [RESEND PATCH v5 0/6] Add support for PWM input capture on STM32 Date: Wed, 16 May 2018 09:35:55 +0200 Message-ID: <1526456161-27865-1-git-send-email-fabrice.gasnier@st.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.75.127.44] X-ClientProxiedBy: SFHDAG3NODE1.st.com (10.75.127.7) To SFHDAG5NODE3.st.com (10.75.127.15) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-05-16_03:,, signatures=0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This series adds support for capture to stm32-pwm driver. Capture is based on DMAs. - First two patches add support for requesting DMAs to MFD core - Next three patches add support for capture to stm32-pwm driver - This has been tested on stm32429i-eval board. --- Changes in v5: - update patch 2 (mfd: stm32-timers: add support for dmas) move stm32_timers_dma struct to header file, fix warning on dma_mapping_error(). Changes in v4: - Lee's comments on patch 2 (mfd: stm32-timers: add support for dmas) Add kerneldoc header, better format comments. Changes in v3: - Dropped 2 precusor patches applied by Thierry in pwm tree: "pwm: stm32: fix, remove unused struct device" "pwm: stm32: protect common prescaler for all channels" - Note: this series applies on top on pwm tree - Implements Lee's comments on MFD part: rework stm32_timers_dma struct, exported routine prototype now use generic device struct, more various comments (see patch 2 changelog). Resend v2: - Add collected Acks Changes in v2: - Abstract DMA handling from child driver: move it to MFD core - Rework pwm capture routines to adopt this change - Comment on optional dma support, beautify DMAs probe Fabrice Gasnier (6): dt-bindings: mfd: stm32-timers: add support for dmas mfd: stm32-timers: add support for dmas pwm: stm32: add capture support pwm: stm32: improve capture by tuning counter prescaler pwm: stm32: use input prescaler to improve period capture ARM: dts: stm32: Enable pwm3 input capture on stm32f429i-eval .../devicetree/bindings/mfd/stm32-timers.txt | 20 ++ arch/arm/boot/dts/stm32429i-eval.dts | 3 + drivers/mfd/stm32-timers.c | 201 +++++++++++++++- drivers/pwm/pwm-stm32.c | 257 +++++++++++++++++++++ include/linux/mfd/stm32-timers.h | 58 +++++ 5 files changed, 537 insertions(+), 2 deletions(-) -- 1.9.1