Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w0wyK-002M4i-2m for pgsql-hackers@arkaria.postgresql.org; Fri, 13 Mar 2026 07:30:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w0wyH-002JT5-39 for pgsql-hackers@arkaria.postgresql.org; Fri, 13 Mar 2026 07:30:10 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w0wyH-002JSs-2F for pgsql-hackers@lists.postgresql.org; Fri, 13 Mar 2026 07:30:10 +0000 Received: from mail-pf1-x42f.google.com ([2607:f8b0:4864:20::42f]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w0wyG-00000001u4O-0jn1 for pgsql-hackers@lists.postgresql.org; Fri, 13 Mar 2026 07:30:09 +0000 Received: by mail-pf1-x42f.google.com with SMTP id d2e1a72fcca58-829865a8471so1794219b3a.3 for ; Fri, 13 Mar 2026 00:30:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1773387007; x=1773991807; darn=lists.postgresql.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=BKJsWsHJ0OIKrypWl7oT90cvaumXE5WMjr+yPowyI9c=; b=i9KGNjMR214mZlDCmGs+eiV/DclylMOmZFVlE1ILhV5IoVttPbddKbTbhrClP6EGKG 4VgSSybellP6lzsrYLUeZ94Q3r8tsZYPm6RWzs3uspwHnLEjQuDfAgRso0POLNNmY2Lf dda9NdeiKONYpQPlhdHcbgImxP3FmzaBluxxaSxvxSPd2Ne6eJNh/s6MQRr4Hkjsh14X oQq3akATOn8aMn6/C/xWk8wirnrTSvWQiHz5afS4FZ9VkhTLMeXb9RROqANZyPPYEa4I asMEQ8mR2VOIoQ+zDta2ZJwd5QQp8+SgolRiSO91VQZ3166oivy3F/4N3acKcw81AL6F AAvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773387007; x=1773991807; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=BKJsWsHJ0OIKrypWl7oT90cvaumXE5WMjr+yPowyI9c=; b=DI/DbS8wrqvTBG3hY6oimoS+Oa12drHr+7MikOuGCdRPVPUuctdt2NIiZ/wn71q/oK D8NyxXGQljbBefa9O/XvqdOfj2v9H8+dXv571c60f+HTLHeBzWV5TeuwiMk3sjbtNzWB DOqldrPbTRQyC02f0LkHRyWfcedfenHW8bT+Pj7jux7jDtGoTi5A558QkdlVYZunIcVj HQcMqBJpvipCDpN1myB9I/ad4KuuSPY76Zeyjpp2JD8lCs10FNkfLiW3qKIKEoPw9V0M j5RG7Uq161/ippQuedRhwxPo+j9qsRH8sP5urUzwBcCRgDekgerchf2CGpgW05nmQ87K g//A== X-Gm-Message-State: AOJu0YwxDlw+2VGfCxk2LLLxjnJCEFogLIpPwj6gAW00WUV1Dd+jccnx MsJvH5tDvd/r2YxbyKYUR59QsSRMhMy4W3MpdQL1n4xjikBuhHpjahnI1UtFxQPC X-Gm-Gg: ATEYQzy71bTzQRRrxtGxHagIO5qiOqCK0Dhaqi5VClig7gqUNAzLxcD6d4fe5HbtjGM uNqbPxTV8mpZdYBK8+dJr7PKchh9WNtSyNQVClV4iW8zh6ZruF1vvsLMoIJQtNFKw9QDXOAxqBI XWVN+MMr35aJZUgXF43pbzAptIOUNBqB0fkIJ2q9aUaeWmJ3Txx+ezELejCEIoX6KIE3I+CCS6X uBAwYqOQhoF61r+ABp60F1oLmMvM0weSM/17/ShdU3i306sFKX+sghRTxwIPK+m0TlcraGxKmtw yiV4LObmGmEATX+KO9ZNgjYEh2Twl/tjy/5OdignjdmSEa3BZdedusdq5ngxgSEd/Lq0BgVfbLj kaw9wgNKw3FKtELrZQ5poO4wRj4DVBIllQMZ129JMT6ElYAoNKmdriN/mfXv/g/blzxivr1kWyY TXGkY8B7toCXCuNl7So71N1qj2yIvaz8s= X-Received: by 2002:a05:6a00:1704:b0:82a:1185:80b4 with SMTP id d2e1a72fcca58-82a198ec7b5mr2115771b3a.35.1773387007242; Fri, 13 Mar 2026 00:30:07 -0700 (PDT) Received: from smtpclient.apple ([45.32.121.103]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-82a07393098sm5075788b3a.62.2026.03.13.00.30.05 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 13 Mar 2026 00:30:06 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.400.21\)) Subject: Re: Use SMgrRelation instead of SMgrRelationData * in pgaio_io_set_target_smgr() From: Chao Li In-Reply-To: Date: Fri, 13 Mar 2026 15:29:31 +0800 Cc: PostgreSQL Hackers Content-Transfer-Encoding: quoted-printable Message-Id: <96EB95E4-9032-44A6-A397-153256AA5E4D@gmail.com> References: To: Japin Li X-Mailer: Apple Mail (2.3864.400.21) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk > On Mar 13, 2026, at 15:05, Japin Li wrote: >=20 >=20 > Hi, hackers >=20 > While reading smgr.h, I noticed an inconsistent type usage in > pgaio_io_set_target_smgr(). Currently the function is declared as: >=20 > extern void pgaio_io_set_target_smgr(PgAioHandle *ioh, > SMgrRelationData *smgr, > ForkNumber forknum, > BlockNumber blocknum, > int nblocks, >=20 > However, SMgrRelation is defined as "typedef SMgrRelationData * = SMgrRelation;", > and all other functions in the smgr subsystem use SMgrRelation as the = parameter > type. >=20 > To keep the code consistent with the rest of the smgr API, this patch = changes > the parameter from SMgrRelationData * to SMgrRelation in both the = definition > and declaration. >=20 > This is purely a style/consistency cleanup with no functional change. >=20 > Thoughts? Is this change acceptable? >=20 > --=20 > Regards, > Japin Li > ChengDu WenWu Information Technology Co., Ltd. >=20 > pgaio_io_set_target_smgr doesn=E2=80=99t update smgr, so, instead of = =E2=80=9CSMgrRelation=E2=80=9D, I think it=E2=80=99s better to change = the type to "const SMgrRelationData *=E2=80=9D. Best regards, -- Chao Li (Evan) HighGo Software Co., Ltd. https://www.highgo.com/