Skip to content

Commit 880fb4e

Browse files
committed
local: iwyu-ify
1 parent d824726 commit 880fb4e

File tree

11 files changed

+20
-16
lines changed

11 files changed

+20
-16
lines changed

src/backend/storage/aio/aio.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,15 @@
3838

3939
#include "postgres.h"
4040

41-
#include "lib/ilist.h"
4241
#include "miscadmin.h"
4342
#include "port/atomics.h"
44-
#include "storage/aio.h"
4543
#include "storage/aio_internal.h"
4644
#include "storage/aio_subsys.h"
45+
#include "storage/procnumber.h"
4746
#include "utils/guc.h"
4847
#include "utils/guc_hooks.h"
4948
#include "utils/resowner.h"
50-
#include "utils/wait_event_types.h"
49+
#include "utils/wait_event.h"
5150

5251
#ifdef USE_INJECTION_POINTS
5352
#include "utils/injection_point.h"

src/backend/storage/aio/aio_callback.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
#include "postgres.h"
1717

1818
#include "miscadmin.h"
19-
#include "storage/aio.h"
2019
#include "storage/aio_internal.h"
2120
#include "storage/bufmgr.h"
2221
#include "storage/md.h"

src/backend/storage/aio/aio_init.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,12 @@
1515
#include "postgres.h"
1616

1717
#include "miscadmin.h"
18-
#include "storage/aio.h"
1918
#include "storage/aio_internal.h"
2019
#include "storage/aio_subsys.h"
2120
#include "storage/bufmgr.h"
22-
#include "storage/io_worker.h"
2321
#include "storage/ipc.h"
2422
#include "storage/proc.h"
23+
#include "storage/procnumber.h"
2524
#include "storage/shmem.h"
2625
#include "utils/guc.h"
2726

src/backend/storage/aio/aio_io.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,7 @@
1919
#include "postgres.h"
2020

2121
#include "miscadmin.h"
22-
#include "storage/aio.h"
2322
#include "storage/aio_internal.h"
24-
#include "storage/fd.h"
2523
#include "utils/wait_event.h"
2624

2725

src/backend/storage/aio/aio_target.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414

1515
#include "postgres.h"
1616

17-
#include "storage/aio.h"
1817
#include "storage/aio_internal.h"
1918
#include "storage/smgr.h"
2019

src/backend/storage/aio/method_io_uring.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,12 @@
2525
#include "postgres.h"
2626

2727
/* included early, for IOMETHOD_IO_URING_ENABLED */
28-
#include "storage/aio.h"
28+
#include "storage/aio.h" /* IWYU pragma: keep */
2929

3030
#ifdef IOMETHOD_IO_URING_ENABLED
3131

3232
#include <liburing.h>
33+
/* IWYU pragma: no_include <liburing/io_uring.h> */
3334

3435
#include "miscadmin.h"
3536
#include "storage/aio_internal.h"

src/backend/storage/aio/method_worker.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,17 @@
3434
#include "port/pg_bitutils.h"
3535
#include "postmaster/auxprocess.h"
3636
#include "postmaster/interrupt.h"
37-
#include "storage/aio.h"
3837
#include "storage/aio_internal.h"
3938
#include "storage/aio_subsys.h"
4039
#include "storage/io_worker.h"
4140
#include "storage/ipc.h"
4241
#include "storage/latch.h"
42+
#include "storage/lwlock.h"
43+
#include "storage/lwlocknames.h"
4344
#include "storage/proc.h"
45+
#include "storage/procsignal.h"
46+
#include "storage/shmem.h"
47+
#include "storage/waiteventset.h"
4448
#include "tcop/tcopprot.h"
4549
#include "utils/ps_status.h"
4650
#include "utils/wait_event.h"

src/include/libpq/pqsignal.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef PQSIGNAL_H
1414
#define PQSIGNAL_H
1515

16-
#include <signal.h>
16+
#include <signal.h> /* IWYU pragma: export */
1717

1818
#ifdef WIN32
1919
/* Emulate POSIX sigset_t APIs on Windows */

src/include/storage/aio.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#ifndef AIO_H
1919
#define AIO_H
2020

21-
#include "storage/aio_types.h"
21+
#include "storage/aio_types.h" /* IWYU pragma: export */
2222
#include "storage/procnumber.h"
2323

2424

@@ -293,7 +293,7 @@ extern ProcNumber pgaio_io_get_owner(PgAioHandle *ioh);
293293
extern void pgaio_io_get_wref(PgAioHandle *ioh, PgAioWaitRef *iow);
294294

295295
/* functions in aio_io.c */
296-
struct iovec;
296+
struct iovec; /* IWYU pragma: export */
297297
extern int pgaio_io_get_iovec(PgAioHandle *ioh, struct iovec **iov);
298298

299299
extern PgAioOp pgaio_io_get_op(PgAioHandle *ioh);

src/include/storage/aio_internal.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,12 @@
1616
#define AIO_INTERNAL_H
1717

1818

19+
/* IWYU pragma: begin_exports */
1920
#include "lib/ilist.h"
2021
#include "port/pg_iovec.h"
2122
#include "storage/aio.h"
2223
#include "storage/condition_variable.h"
24+
/* IWYU pragma: end_exports */
2325

2426

2527
/*
@@ -90,8 +92,11 @@ typedef enum PgAioHandleState
9092
} PgAioHandleState;
9193

9294

95+
/* IWYU pragma: begin_exports */
9396
struct ResourceOwnerData;
9497

98+
/* IWYU pragma: end_exports */
99+
95100
/* typedef is in aio_types.h */
96101
struct PgAioHandle
97102
{

0 commit comments

Comments
 (0)