From patchwork Thu Aug 19 11:13:04 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Loic Poulain X-Patchwork-Id: 499731 Delivered-To: patch@linaro.org Received: by 2002:a02:6f15:0:0:0:0:0 with SMTP id x21csp406132jab; Thu, 19 Aug 2021 04:02:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJztb6LKBH7f+nSjno4sJOscM08E45CRR9Qyl40/yGD+MloGQbubcnRCsTGcM4Prv4MyNifZ X-Received: by 2002:a17:906:cb99:: with SMTP id mf25mr15122091ejb.441.1629370968418; Thu, 19 Aug 2021 04:02:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629370968; cv=none; d=google.com; s=arc-20160816; b=o/CznlliYoMxvlKyDXNmslBrRaEJsrYcnqGUYQ5LgdXhAKc2V6C4OmDEMkOpHXOj0c T3zaDy0YGltExzwV/nDai/Nv2YtHovT526so6NlEAKrnvDH+AJYGzrk26ZUnb1KYETBJ N3NcTn6Uhq7LUwRCcD79ocGdaAjDuP79DVEf9fuFSRvsdcbOF8BA1wT685gqjx4j0D+x njzWHC2NNccRpaPvJ4z1zXc4v5MIdnU1S6YscGMKAL+dKxpArxzNNVjPuLE46PdeZlSk AR+PTgrIGh03pwWDBFYsMU/3PgwHMjyV2n//LirR2kER8ysZOBXMpdyayuwnZt1CoOCS Ydew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=1GxHIdTJ9bLTkBzyGG12Iq5o9eH+I3P3+ODLSSyLBhg=; b=gnO3OZ/AFaE11h3PefMoR2eTA2TyGBz9r1EWHQ4OTjaDnXdSXcJx4yazIsvoc1W/5R KXjC4Ts4q83xPsmB6jCxcTwHlObXcPzHVaFjd9y1t+Y5g7xW5rSRM+9qiYKo3beH/YjN ZrTjS2cRg2eW0i/0Qge4CORU5hCj3tF7oTd46fnIel0iNUwCuEXjidkL2VCasI2Fk1J3 X2sDo24C6EQPCg5HkEi9xIStD+o6vtBjsNvTyL890QSfCccKMDwaQBqMnPQnGW4DLlkR nOSH/c1WCy5gyp2GDa60/k4V9WFCXJ0XU2znKaL2ueEFdzo2WZMrfQ4v031kdYwFMnLo DEzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=sq92RYil; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id v4si2800537edy.547.2021.08.19.04.02.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Aug 2021 04:02:48 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=sq92RYil; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 6E93D82DB2; Thu, 19 Aug 2021 13:02:44 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="sq92RYil"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6DCAF82E1B; Thu, 19 Aug 2021 13:02:41 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-wm1-x32e.google.com (mail-wm1-x32e.google.com [IPv6:2a00:1450:4864:20::32e]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 68C5282C39 for ; Thu, 19 Aug 2021 13:02:37 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=loic.poulain@linaro.org Received: by mail-wm1-x32e.google.com with SMTP id w21-20020a7bc1150000b02902e69ba66ce6so3797819wmi.1 for ; Thu, 19 Aug 2021 04:02:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=1GxHIdTJ9bLTkBzyGG12Iq5o9eH+I3P3+ODLSSyLBhg=; b=sq92RYillYM4bkx0zwc91On4LL15/pA3VayU67hX+JqAeLkJXHEi2Nsh2VG2s5b4LA frrLbRSOWlsnEq23vOFuiY977iCZOM/LD/34Rt3riUxSQNg4TeuXI9AlVsg9NtT7E2+X AQ4SzwuhCbc+bV0U8VYVlvVpiNI9AahKbhLl1pmdPSlSUkRclqZXBOrrHr+rMJt7QTJp R6XFa1kCzsDXINuqgwmubh+w6uHtnjh7XhVMQyr9KMTsYSQputHlColZeRrGvfJz36tY 8clqCeKjxi976QcQI/62P/0Vro5WbXc1b9qXiqhJyKOCY6d7tJhxcLMFDkGJ/z68S00U liWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=1GxHIdTJ9bLTkBzyGG12Iq5o9eH+I3P3+ODLSSyLBhg=; b=rMm1vP9eC5SR4PciyQu2aOwR6iaOLd4eAsJG4g2fpE3spZ/ES+1UOuPp50mplq8oah y/+glPQ9EgvvuOCsxwPrx11jqLxdmHb19m4+EER7q1w3T6sZo7EnZmC9PEIgS06nRmnC uwbIw9plV2yTRU2ZPNN4xU8shvhQnleK3Y+ziG8SWLUpCs66vapq6RJgFyLrTETRAo/E ZJpMzjUssNqvOy/2hDZcg+qIJRb6obgRQ2KziHb1DiS7nIYff1XKFIbEOs6WyG5kb2uR oiAezKgacLVlJkjHrK4W1EmaM36f5r0x82F8xnc/stiXzpr+fvRApZ72MRYo5cMzGngO QFFA== X-Gm-Message-State: AOAM530j83YiBrNdYzj4SnXgl3PV/zc27qLKjC++kcSKp3q4qZjwv/80 q+Vg8Rmw25ZSPOuUR6kt8i7tKw== X-Received: by 2002:a1c:10e:: with SMTP id 14mr13139775wmb.93.1629370956896; Thu, 19 Aug 2021 04:02:36 -0700 (PDT) Received: from lpoulain-ThinkPad-T470p.passengers.t31.sncf ([109.190.253.13]) by smtp.gmail.com with ESMTPSA id d8sm2705696wrv.20.2021.08.19.04.02.30 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Aug 2021 04:02:36 -0700 (PDT) From: Loic Poulain To: marex@denx.de Cc: u-boot@lists.denx.de, lukma@denx.de, Loic Poulain Subject: [PATCH 1/3] lib/circbuf: Make circbuf selectable symbol Date: Thu, 19 Aug 2021 13:13:04 +0200 Message-Id: <1629371586-9349-1-git-send-email-loic.poulain@linaro.org> X-Mailer: git-send-email 2.7.4 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean It is currenly only used from usbtty driver but make it properly selectable via Kconfig symbol, for future usage. Signed-off-by: Loic Poulain --- lib/Kconfig | 3 +++ lib/Makefile | 8 +++++++- 2 files changed, 10 insertions(+), 1 deletion(-) -- 2.7.4 diff --git a/lib/Kconfig b/lib/Kconfig index c535147..1bd54d8 100644 --- a/lib/Kconfig +++ b/lib/Kconfig @@ -290,6 +290,9 @@ config TRACE_EARLY_ADDR the size is too small then the message which says the amount of early data being coped will the the same as the +config CIRCBUF + bool + source lib/dhry/Kconfig menu "Security support" diff --git a/lib/Makefile b/lib/Makefile index 8ba745f..4daeee2 100644 --- a/lib/Makefile +++ b/lib/Makefile @@ -29,7 +29,13 @@ ifneq ($(CONFIG_CHARSET),) obj-y += charset.o endif endif -obj-$(CONFIG_USB_TTY) += circbuf.o + +ifdef CONFIG_USB_TTY +obj-y += circbuf.o +else +obj-$(CONFIG_CIRCBUF) += circbuf.o +endif + obj-y += crc8.o obj-y += crc16.o obj-$(CONFIG_ERRNO_STR) += errno_str.o