From patchwork Tue Aug 19 18:58:37 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 8 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755630039; bh=OxEBPWv6234YZWfaM74UtPVNF1ppnd212Yjp7IX8w9c=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=OrS7StVBpj7XqCscUBdZbE3vsHb9TwswWL3j60x+Ncxi8GGjGU1+pE1rPy2PIzN1k WpylnmR+i1fMuLnS5zUUZBVXDLUXA6xXCtBc+SFDbfT2wj6zKqhxmixZxMmNLx3P3x bLZFOoiO+zhkKhgu0pymNac7U6wruoNtU5duNJNGqARSCjR5EcBIC2LJtZTeQJYxJk iuAQScyxRIZFUcAMOwKa9ke78qcJuvGUUNFqJfqRcN8WddbiFEwLmIHRadmO2nu9t+ KVj7Fof6b6ueGbarE3hLn2jvgROB6QUizbPN7A2XoFuwCvUau12RGpiZNVkikbXILk jT22KgOF+upaw== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 1802167604 for ; Tue, 19 Aug 2025 13:00:39 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id L96Zrae55CKu for ; Tue, 19 Aug 2025 13:00:39 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755630037; bh=OxEBPWv6234YZWfaM74UtPVNF1ppnd212Yjp7IX8w9c=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=cPhneHej2tI8z6aCb+d7QwU9sMyF71tv5Ajb+RtRSksdbKvdDWvaYN7RtsWbeHG5/ cZtu4RYiUqG+Z8BkkB7k3n7Q++NXg6EPd6pERjOzpLODjH5Nauy+Rc2miC+EtnMBIh FnERQHGZN3Ur3x/Gi9/kFxLJBVE0eON9ArRZNu7lGomxqhJPDJY1panhbO8LQXTxk8 gw7v/R0YDPUxCY4SjL4v4gYCz92bzLDL2+KtMQ5nbt467xEScoQo/8VJQR9Inlgqrx 0izNDU3ycklty/S4S2aoyKn4sSsUimh2hk4AhxaghPXnix8jBWK1sG6NOrwTKEh3Yf 2vzlYwMD93bMw== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 2B7EE6760A for ; Tue, 19 Aug 2025 13:00:37 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755630036; bh=ch6bTKu6kyq/z20mAPoT1fEuvYO/uM4VaWbQxAgF0Io=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=DaPTFA/YlZ7vP5xzKCo1t+s4p4rThHL51TJdEuWS78rLtM7vha537TeGhwnmnVMyJ kvoeDA1PRgjzH252xxKc22SQYSmEXd+y35cc+DeacJqtBw/N0Dv6UVKbV2P1HBSkZr 3uBpOoM1s/OzW1GAsDAtiBauuG+OLEB7vB1CHy3dJjQHifh2oZSz6eosSPsIwgy4Ea NLAw5QPjE7Yo9F8eVoJiF3TLy17xIyqr1fKS06/rCNdrHDVm7IPac2p4ojiGnyI/FF QakG2e1SLua1cQ1UJ3Kdq5mM0ZguMy6DxLRPEg2zmeao0Pap7rQEzKcai5csxUPSwW V9y2G7Z2Mj3Og== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 04461675F3; Tue, 19 Aug 2025 13:00:36 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id DsqPexbIGbw5; Tue, 19 Aug 2025 13:00:35 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1755630035; bh=LH1pO5qV20eRIRQ1t6opg6OZGTBC20jLGWFKcG2ie0U=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WtsfICYObES5jbuEgP8HsDlumJKNWqZ+swzPznsj6vaTUGezSFicVPe7LEJfdAxPS spd+dkV4BsIAE42380QiEo4s0iZ/tWG70m9Ja+rNrykBfcjznhRqr6j+nuHN+cq6QS mDKDPfQT7HQgcWLje4DtTA0riVL/EldKgy0qS48naJbjMEM/VFEKCjHDwh4fa/TXCl +KgRrLyc1MGhR9ZjRE9AlIdMuSmJErzX7lNVvcZJorCfYD3RwigYq2Z8X3o/0KXcHa K0JmrnyO0JFAui2wehqUaN0FtFOZwND/9mTsCCp2B+3bI8jA5R9+mfvhU9eAB2lsBp jintA80Yfgcqw== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 808C7675EE; Tue, 19 Aug 2025 13:00:35 -0600 (MDT) From: Simon Glass To: U-Boot Concept Date: Tue, 19 Aug 2025 12:58:37 -0600 Message-ID: <20250819185900.835939-7-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250819185900.835939-1-sjg@u-boot.org> References: <20250819185900.835939-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: QHGTRKELPIRM3MWHX22MD4OSOQVIYXXU X-Message-ID-Hash: QHGTRKELPIRM3MWHX22MD4OSOQVIYXXU X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Simon Glass X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH v2 06/22] event: Add a dummy function for event_notify() List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass When CONFIG_EVENT is disabled, we should not try to send an event. This is already handled for events without parameters, so handle it for events that do have parameters, too. Signed-off-by: Simon Glass --- (no changes since v1) include/event.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/include/event.h b/include/event.h index 67b5bdd8a8b..a68be9fc1e8 100644 --- a/include/event.h +++ b/include/event.h @@ -402,6 +402,7 @@ void event_show_spy_list(void); */ const char *event_type_name(enum event_t type); +#if CONFIG_IS_ENABLED(EVENT) /** * event_notify() - notify spies about an event * @@ -416,7 +417,6 @@ const char *event_type_name(enum event_t type); */ int event_notify(enum event_t type, void *data, int size); -#if CONFIG_IS_ENABLED(EVENT) /** * event_notify_null() - notify spies about an event * @@ -431,6 +431,11 @@ static inline int event_notify_null(enum event_t type) { return 0; } + +static inline int event_notify(enum event_t type, void *data, int size) +{ + return 0; +} #endif #if CONFIG_IS_ENABLED(EVENT_DYNAMIC)