Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp7833700ioo; Fri, 3 Jun 2022 14:49:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzf2CBUZeUzXKinaMRakzr273D/YL3PTlG7z2F9I8hFZYGu9qxJ3Wpz+hz9hsAiux8Ifj1D X-Received: by 2002:a05:6a00:138e:b0:51b:c205:ff2c with SMTP id t14-20020a056a00138e00b0051bc205ff2cmr11866686pfg.25.1654292997252; Fri, 03 Jun 2022 14:49:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654292997; cv=none; d=google.com; s=arc-20160816; b=uKg5FvM8Ezs17mvzZIWIe9Qx7l0u2zYl89fKa4mRhklEkFJrMnKSDfmZo+PvhGOL5/ hcKdoAUeMejGhrryhKpLaz76zChwvQ0+Tk5MO+TDvv9AkNei5MF3Tgeky9RrudusMl70 AMo1PAi9KieNyuZGkjSykEv+yR7qH4SLoEgbT6VHFMqW4VQutzdyqbpNLTD8Y15E23SR ui0XfgvsWBPNm3mPyLb0DApayFNzhQrlUfUV4Cb03fZjejeMQKFi8WDQAhyu4pPDap/2 gwUSbGZGcoTvD0i5DdO2/7tsldft23umGIE9xfrbSJFyhdel8fKbhMA3Vj7NIKSn0D+7 9x9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=NLcd3Cw3hjI1NfLbhZ7+1EK5axo7GcECogVJtB2kQoo=; b=DPgYUKZzsOyE7BeaTmyL+MAqeu2nB1niHpC1oh3L5W+VNvlGj5ki2zAJGNUpZSH+p9 nJrIwinH2ED3xjXGscSmUvTXXrydqPBpaJ3w5UF6/AV6zLNfk0sTcOq+7aMKN8xUFnzR 9MIWgg3eXDVngSN8t6zG9tv/s4uvzPMxFpQ8NdgH7zBh4A/h1h5d97YxuWZliSiBat3H YQFYtDqsneqjHzKXyHknv54cn0dDyUIkNQG4zBk84Pxz2nPMacNOKCLcD5kYtdfHD7JZ 7pfl0JWDxZj2tzd12s6qDUUd4S+rSFn4AJE/vZJ0jUeiPRL/PPYUHuvFwXj3aJ5z/aRW 57yA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=n63Lg6qy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id lb15-20020a17090b4a4f00b001dc7934acb3si14418268pjb.127.2022.06.03.14.49.44; Fri, 03 Jun 2022 14:49:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=n63Lg6qy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1349282AbiFCT27 (ORCPT + 99 others); Fri, 3 Jun 2022 15:28:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40574 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241021AbiFCT25 (ORCPT ); Fri, 3 Jun 2022 15:28:57 -0400 Received: from mail-ed1-x52a.google.com (mail-ed1-x52a.google.com [IPv6:2a00:1450:4864:20::52a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 23EFB580F3 for ; Fri, 3 Jun 2022 12:28:56 -0700 (PDT) Received: by mail-ed1-x52a.google.com with SMTP id 25so11145314edw.8 for ; Fri, 03 Jun 2022 12:28:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NLcd3Cw3hjI1NfLbhZ7+1EK5axo7GcECogVJtB2kQoo=; b=n63Lg6qyTjWXwuTeS8v+72aLJUJKw4vX/fzlGVF9KlWhmWjFlvsfSiHMmLjmJq8wL+ J1+x0KJSnIYLk4zcB8ymTQjBIInkv9QNNiGw+gbTuk6Agp3JicslpgubNSGLpQP5/Qnp V13l+3GFTz3kWlwBXsM4/d9NyoyY6+LvUMNLw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NLcd3Cw3hjI1NfLbhZ7+1EK5axo7GcECogVJtB2kQoo=; b=S3T9CWb1+GsntUIDMGBrf307Bu7FnqQXUZhn6tdM7cOlIJzRMquCeUgLuBxv8eYRix UDQt/PkbAb0WUje+AgRmk1mpPPqTColmAEoyw5mbg5Q5iHWgv4qK6MqtAhPFI50vAn1n Co5IDuPZQEVB44cWf2LeapWXpTTrddKEP5jobZJFKF6al+P7AfC8WXVnoT3ark8WNI5F 13vhlnfrsenPhKlvm6LtSv/KScXSSXqeIN8gR/noS7wz6rD7tlwZaebQPfmY5UhBsJf7 HruN8USAE4MG+o2jVpqXsAXKmg7uHjQJ1aSANJM+hK9oYQqKi83PLIRy4t0OhpQoW+z3 tpAg== X-Gm-Message-State: AOAM530Cq/ENWnW+8szq8g3+AprFGoiiEcd+EAvJflI9tsASIjt9jWqE 5Gt9XwNMnZQk0y8Q7ByhTEiStvO3DZ/B4qZqSPU= X-Received: by 2002:a05:6402:3207:b0:42d:dba6:8ef0 with SMTP id g7-20020a056402320700b0042ddba68ef0mr12848941eda.410.1654284534530; Fri, 03 Jun 2022 12:28:54 -0700 (PDT) Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com. [209.85.221.41]) by smtp.gmail.com with ESMTPSA id g8-20020a170906520800b006feb3d65337sm3151649ejm.102.2022.06.03.12.28.51 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 03 Jun 2022 12:28:51 -0700 (PDT) Received: by mail-wr1-f41.google.com with SMTP id p10so11578982wrg.12 for ; Fri, 03 Jun 2022 12:28:51 -0700 (PDT) X-Received: by 2002:a5d:6483:0:b0:20f:d046:6382 with SMTP id o3-20020a5d6483000000b0020fd0466382mr9544675wri.342.1654284530598; Fri, 03 Jun 2022 12:28:50 -0700 (PDT) MIME-Version: 1.0 References: <1652692810-31148-1-git-send-email-quic_vnivarth@quicinc.com> <3866c083-0064-ac9a-4587-91a83946525d@samsung.com> In-Reply-To: From: Doug Anderson Date: Fri, 3 Jun 2022 12:28:38 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [V4] serial: core: Do stop_rx in suspend path for console if console_suspend is disabled To: Vijaya Krishna Nivarthi Cc: Marek Szyprowski , Greg Kroah-Hartman , Jiri Slaby , linux-serial@vger.kernel.org, LKML , quic_msavaliy@quicinc.com, Matthias Kaehlcke , Stephen Boyd Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On Fri, Jun 3, 2022 at 11:54 AM Vijaya Krishna Nivarthi wrote: > > >>> Add a start_rx in uart_resume_port after call to set_termios to handle > >>> this scenario for other drivers. > > Since start_rx is not exposed it doesn't seem like we will be able to > handle it in core. > > In your drivers, Can we add a call to stop_rx at begin of set_termios > and then undo it at end? > > That would ensure that set_termios functionality is unaffected while > fixing the broken cases? > > If that's not an option we will have to go back to a previous version of > limiting the change to qcom driver. How about this: add an optional start_rx() callback to "struct uart_ops" and then only do your stop_rx() logic in uart_suspend_port() if you'll be able to start it again (AKA if the start_rx() callback is not NULL). That keeps the logic in the core. -Doug