From patchwork Mon Dec 19 11:57:18 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 3088 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp2343324wrn; Mon, 19 Dec 2022 04:01:58 -0800 (PST) X-Google-Smtp-Source: AMrXdXvZ3lkwyO9oQW66huIj1EAwyl3FCYR90h89mxWn/HeSz0CNlFM4Rl4yE/BqrzCTvtLY6ByI X-Received: by 2002:a17:90a:d910:b0:213:9bf5:6a10 with SMTP id c16-20020a17090ad91000b002139bf56a10mr8642399pjv.49.1671451317902; Mon, 19 Dec 2022 04:01:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671451317; cv=none; d=google.com; s=arc-20160816; b=dxaGB05305kuzMAejHUum1Cn1oQqM+cjF7lRTnasjpIvVRJdYPC4uCMdOeUUJqjMGk bcn8vLTntgKHOSde7fZnLDLoA93Qb2vnYLa++qefSeOM/iTJi1pdhVSoo0tq5y3iyeYQ 7c+ImuWjKxfrzgnzMIndwJw2BVC0FQvv5FarX/pLdHGoGtlaa9kaYWcZ84kCl3xVw5O7 jVe/z5TIM1KYv79QOKcASMGfgIo2H3nGvvZ0Ak2EaQjzZjexAlYFOwSXLXVNzbUgiv4U +inUNVvA0kFq17nIzNFFcgmfJ2AoR8W4d1s01qV6lgDCAIYJ7madCfhTVXnmYmziDKZB NZFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=wNhYDPyx/KA2zl6TrOJkeNFNNyTRQMLsAP6+eKicMZc=; b=YGu6kIEYlEVFHJ06WUHHqFp6hMxU3ecog8QNbo8sZOWxbgzLpNVQVf0hn33eLdMc0h LX3d19hVMFo9JVKuYc2TxChlQXkJAjs2MDa/+aC3NsGlILil7g6Bph38onu365FlVH4n PaHJjSgGZqy+9FaWQGoxEpf3hj6L9uVJCOIJkR2tK+IiPdodColUEV26OdljsMz0C8sZ H2nF0gYmW6Ho4bHGTFLcDK93Ryu9M+dm4LT9aEnrrmRodJIsd2fLuDh2zGmtkaKnP6NL p79i33fozch1ZkLsVeIR8qMrIqREALkuPUcHPJjLIr86BLZuP4h8HjbwA2a4W6F27GXz 1K5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=Vh4K3fIe; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v135-20020a63618d000000b004777f68f798si10077834pgb.814.2022.12.19.04.01.45; Mon, 19 Dec 2022 04:01:57 -0800 (PST) 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 (test mode) header.i=@ideasonboard.com header.s=mail header.b=Vh4K3fIe; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231841AbiLSL5t (ORCPT + 99 others); Mon, 19 Dec 2022 06:57:49 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48538 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231248AbiLSL5q (ORCPT ); Mon, 19 Dec 2022 06:57:46 -0500 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [213.167.242.64]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CF0868FFC; Mon, 19 Dec 2022 03:57:45 -0800 (PST) Received: from umang.jainideasonboard.com (unknown [IPv6:2401:4900:1f3e:7d24:3f0:3e81:fb16:ab4d]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 5ECF1825; Mon, 19 Dec 2022 12:57:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1671451062; bh=Go7MiR3dYCV2jmv6BwP/3GC/SWENkVqsP5a91fdMktY=; h=From:To:Cc:Subject:Date:From; b=Vh4K3fIeW5NVh9gjKZnW8nIBvVQFqGp5+Iw5qgdIjcWeMoiW2dn8Jx/IN7HkVCoIM CgiCVA1k03nvVCCJtPkQPBsDXAcYUMpJlHLv6/okdpCMhXIap9nAlFK3/s43D1CGTn 4ihvtNBgeOSWoni+UGaOdjMbrDHN3WIeDI10YuJI= From: Umang Jain To: linux-staging@lists.linux.dev, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Kees Cook , Stefan Wahren , Greg Kroah-Hartman , Florian Fainelli , Adrien Thierry , Dan Carpenter , Dave Stevenson , Kieran Bingham , Laurent Pinchart , Umang Jain Subject: [PATCH v2 0/7] staging: vc04_services: Remove custom return values Date: Mon, 19 Dec 2022 17:27:18 +0530 Message-Id: <20221219115725.11992-1-umang.jain@ideasonboard.com> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 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_PASS,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752643737285083276?= X-GMAIL-MSGID: =?utf-8?q?1752643737285083276?= The series removes the custom return values from functions and replaces them with linux error codes. This address the TODO vchiq interface: * Get rid of custom function return values Changes in V2: - Patch 3/7 now reports for specific errors like -ENOMEM, -EHOSTDOWN - Patch 5/7 reports -ENOTCONN instead of -EINVAL and adds a "Fixes" tag Umang Jain (7): staging: vc04_services: Replace vchiq_status return type to int staging: vc04_services: Drop VCHIQ_SUCCESS usage staging: vc04_services: Drop VCHIQ_ERROR usage staging: vc04_services: Drop VCHIQ_RETRY usage vc04_services: vchiq_arm: Drop VCHIQ_RETRY usage on disconnect staging: vc04_services: Drop enum vchiq_status remnants staging: vc04_services: vchiq: Drop custom return values from TODO .../bcm2835-audio/bcm2835-vchiq.c | 12 +- .../include/linux/raspberrypi/vchiq.h | 65 +++--- drivers/staging/vc04_services/interface/TODO | 5 - .../interface/vchiq_arm/vchiq_arm.c | 124 +++++----- .../interface/vchiq_arm/vchiq_arm.h | 12 +- .../interface/vchiq_arm/vchiq_core.c | 216 +++++++++--------- .../interface/vchiq_arm/vchiq_core.h | 18 +- .../interface/vchiq_arm/vchiq_dev.c | 36 +-- .../interface/vchiq_arm/vchiq_ioctl.h | 8 +- .../vc04_services/vchiq-mmal/mmal-vchiq.c | 11 +- 10 files changed, 246 insertions(+), 261 deletions(-) Tested-by: Stefan Wahren