Skip to content

Commit 400d8fc

Browse files
authored
Merge pull request #678 from uyjulian/whole_revert_625
[NFC] Revert #625
2 parents ed5ead7 + 37d6c12 commit 400d8fc

File tree

23 files changed

+419
-317
lines changed

23 files changed

+419
-317
lines changed

iop/arcade/accdvd/src/cddrv.c

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,27 +18,26 @@ static int cddrv_read(iop_file_t *io, void *buf, int cnt);
1818
static int cddrv_write(iop_file_t *io, void *buf, int cnt);
1919
static int cddrv_lseek(iop_file_t *io, int offset, int whence);
2020
static int cddrv_ioctl(iop_file_t *io, int cmd, void *arg);
21+
static int cddrv_dummy();
2122

22-
2323
static iop_device_ops_t Cddrv_ops = {
2424
&cddrv_adddrv,
2525
&cddrv_deldrv,
26-
NOT_SUPPORTED,
26+
&cddrv_dummy,
2727
&cddrv_open,
2828
&cddrv_close,
2929
&cddrv_read,
3030
&cddrv_write,
3131
&cddrv_lseek,
3232
&cddrv_ioctl,
33-
NOT_SUPPORTED,
34-
NOT_SUPPORTED,
35-
NOT_SUPPORTED,
36-
NOT_SUPPORTED,
37-
NOT_SUPPORTED,
38-
NOT_SUPPORTED,
39-
NOT_SUPPORTED,
40-
NOT_SUPPORTED
41-
};
33+
&cddrv_dummy,
34+
&cddrv_dummy,
35+
&cddrv_dummy,
36+
&cddrv_dummy,
37+
&cddrv_dummy,
38+
&cddrv_dummy,
39+
&cddrv_dummy,
40+
&cddrv_dummy};
4241

4342
static iop_device_t Cddrv = {"cdrom", 16u, 0u, "ATAPI_C/DVD-ROM", &Cddrv_ops};
4443

@@ -159,6 +158,11 @@ static int cddrv_ioctl(iop_file_t *io, int cmd, void *arg)
159158
return -EINVAL;
160159
}
161160

161+
static int cddrv_dummy()
162+
{
163+
return -EINVAL;
164+
}
165+
162166
int cddrv_module_start(int argc, char **argv)
163167
{
164168
int v2;

iop/cdvd/cdfs/src/main.c

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -418,24 +418,29 @@ static int fio_getstat(iop_file_t *fd, const char *name, io_stat_t *stat)
418418
return ret;
419419
}
420420

421+
static int cdfs_dummy() {
422+
DPRINTF("CDFS: dummy function called\n\n");
423+
return -EIO;
424+
}
425+
421426
static iop_device_ops_t fio_ops = {
422427
&fio_init,
423428
&fio_deinit,
424-
NOT_SUPPORTED,
429+
(void *)&cdfs_dummy,
425430
&fio_open,
426431
&fio_close,
427432
&fio_read,
428433
&fio_write,
429434
&fio_lseek,
430-
NOT_SUPPORTED,
431-
NOT_SUPPORTED,
432-
NOT_SUPPORTED,
433-
NOT_SUPPORTED,
435+
(void *)&cdfs_dummy,
436+
(void *)&cdfs_dummy,
437+
(void *)&cdfs_dummy,
438+
(void *)&cdfs_dummy,
434439
&fio_openDir,
435440
&fio_closeDir,
436441
&fio_dread,
437442
&fio_getstat,
438-
NOT_SUPPORTED,
443+
(void *)&cdfs_dummy,
439444
};
440445

441446
static iop_device_t fio_driver = {

iop/cdvd/xesdrv/src/xesdrv.c

Lines changed: 27 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ static int esdrv_df_devctl(
2828
iomanX_iop_file_t *f, const char *name, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
2929
static int
3030
esdrv_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
31+
static int esdrv_df_null();
3132
static s64 esdrv_df_null_long();
3233
static int
3334
esioctl2_func_1(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
@@ -222,30 +223,30 @@ struct DevctlCmdTbl_t
222223
static iomanX_iop_device_ops_t DvrFuncTbl = {
223224
&esdrv_df_init,
224225
&esdrv_df_exit,
225-
NOT_SUPPORTED,
226-
NOT_SUPPORTED,
227-
NOT_SUPPORTED,
228-
NOT_SUPPORTED,
229-
NOT_SUPPORTED,
230-
NOT_SUPPORTED,
226+
(void *)&esdrv_df_null,
227+
(void *)&esdrv_df_null,
228+
(void *)&esdrv_df_null,
229+
(void *)&esdrv_df_null,
230+
(void *)&esdrv_df_null,
231+
(void *)&esdrv_df_null,
231232
&esdrv_df_ioctl,
232-
NOT_SUPPORTED,
233-
NOT_SUPPORTED,
234-
NOT_SUPPORTED,
235-
NOT_SUPPORTED,
236-
NOT_SUPPORTED,
237-
NOT_SUPPORTED,
238-
NOT_SUPPORTED,
239-
NOT_SUPPORTED,
240-
NOT_SUPPORTED,
241-
NOT_SUPPORTED,
242-
NOT_SUPPORTED,
243-
NOT_SUPPORTED,
244-
NOT_SUPPORTED,
233+
(void *)&esdrv_df_null,
234+
(void *)&esdrv_df_null,
235+
(void *)&esdrv_df_null,
236+
(void *)&esdrv_df_null,
237+
(void *)&esdrv_df_null,
238+
(void *)&esdrv_df_null,
239+
(void *)&esdrv_df_null,
240+
(void *)&esdrv_df_null,
241+
(void *)&esdrv_df_null,
242+
(void *)&esdrv_df_null,
243+
(void *)&esdrv_df_null,
244+
(void *)&esdrv_df_null,
245+
(void *)&esdrv_df_null,
245246
(void *)&esdrv_df_null_long,
246247
&esdrv_df_devctl,
247-
NOT_SUPPORTED,
248-
NOT_SUPPORTED,
248+
(void *)&esdrv_df_null,
249+
(void *)&esdrv_df_null,
249250
&esdrv_df_ioctl2,
250251
};
251252
static iomanX_iop_device_t ESDRV = {
@@ -371,6 +372,11 @@ esdrv_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen, v
371372
return -EINVAL;
372373
}
373374

375+
static int esdrv_df_null()
376+
{
377+
return -EUNSUP;
378+
}
379+
374380
static s64 esdrv_df_null_long()
375381
{
376382
return -EUNSUP;

iop/debug/iop_sbusdbg/src/sbus_tty.c

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ Of course this requires that the EE-side code accept this command and output the
2727

2828
extern void sbus_tty_puts(const char *str);
2929

30+
static int ttyfs_error() { return -EPERM; }
31+
3032
static int ttyfs_init()
3133
{
3234
//DBG_puts("SIOTTY: FS Init()\n");
@@ -96,21 +98,21 @@ static iop_device_ops_t fsd_ops =
9698
{
9799
&ttyfs_init,
98100
&ttyfs_deinit,
99-
NOT_SUPPORTED,
101+
(void *)&ttyfs_error,
100102
&ttyfs_open,
101103
&ttyfs_close,
102-
NOT_SUPPORTED,
104+
(void *)&ttyfs_error,
103105
&ttyfs_write,
104-
NOT_SUPPORTED,
105-
NOT_SUPPORTED,
106-
NOT_SUPPORTED,
107-
NOT_SUPPORTED,
108-
NOT_SUPPORTED,
106+
(void *)&ttyfs_error,
107+
(void *)&ttyfs_error,
108+
(void *)&ttyfs_error,
109+
(void *)&ttyfs_error,
110+
(void *)&ttyfs_error,
109111
&ttyfs_dopen,
110112
&ttyfs_close,
111-
NOT_SUPPORTED,
112-
NOT_SUPPORTED,
113-
NOT_SUPPORTED,
113+
(void *)&ttyfs_error,
114+
(void *)&ttyfs_error,
115+
(void *)&ttyfs_error,
114116
};
115117

116118
static iop_device_t tty_fsd =

iop/debug/ppctty/src/tty.c

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ static int tty_sema = -1;
2626

2727
extern void tty_puts(const char *str);
2828

29+
static int ttyfs_error() { return -EPERM; }
30+
2931
static int ttyfs_init()
3032
{
3133
DPRINTF("FS Init()\n");
@@ -103,21 +105,21 @@ static iop_device_ops_t fsd_ops =
103105
{
104106
&ttyfs_init,
105107
&ttyfs_deinit,
106-
NOT_SUPPORTED,
108+
(void *)&ttyfs_error,
107109
&ttyfs_open,
108110
&ttyfs_close,
109-
NOT_SUPPORTED,
111+
(void *)&ttyfs_error,
110112
&ttyfs_write,
111-
NOT_SUPPORTED,
112-
NOT_SUPPORTED,
113-
NOT_SUPPORTED,
114-
NOT_SUPPORTED,
115-
NOT_SUPPORTED,
113+
(void *)&ttyfs_error,
114+
(void *)&ttyfs_error,
115+
(void *)&ttyfs_error,
116+
(void *)&ttyfs_error,
117+
(void *)&ttyfs_error,
116118
&ttyfs_dopen,
117119
&ttyfs_close,
118-
NOT_SUPPORTED,
119-
NOT_SUPPORTED,
120-
NOT_SUPPORTED,
120+
(void *)&ttyfs_error,
121+
(void *)&ttyfs_error,
122+
(void *)&ttyfs_error,
121123
};
122124

123125
static iop_device_t tty_fsd =

iop/dvrp/dvr/src/dvr.c

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ extern int dvr_df_exit(iomanX_iop_device_t *dev);
3333
extern int dvr_df_ioctl(iomanX_iop_file_t *f, int cmd, void *param);
3434
extern int dvr_df_devctl(iomanX_iop_file_t *a1, const char *name, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
3535
extern int dvr_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
36+
extern int dvr_df_null();
3637
extern s64 dvr_df_null_long();
3738
extern int dvrioctl2_rec_start(iomanX_iop_file_t *a1, const char *name, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
3839
extern int dvrioctl2_rec_pause(iomanX_iop_file_t *a1, const char *name, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
@@ -113,30 +114,30 @@ static iomanX_iop_device_ops_t DvrFuncTbl =
113114
{
114115
&dvr_df_init,
115116
&dvr_df_exit,
116-
NOT_SUPPORTED,
117-
NOT_SUPPORTED,
118-
NOT_SUPPORTED,
119-
NOT_SUPPORTED,
120-
NOT_SUPPORTED,
121-
NOT_SUPPORTED,
117+
(void *)&dvr_df_null,
118+
(void *)&dvr_df_null,
119+
(void *)&dvr_df_null,
120+
(void *)&dvr_df_null,
121+
(void *)&dvr_df_null,
122+
(void *)&dvr_df_null,
122123
&dvr_df_ioctl,
123-
NOT_SUPPORTED,
124-
NOT_SUPPORTED,
125-
NOT_SUPPORTED,
126-
NOT_SUPPORTED,
127-
NOT_SUPPORTED,
128-
NOT_SUPPORTED,
129-
NOT_SUPPORTED,
130-
NOT_SUPPORTED,
131-
NOT_SUPPORTED,
132-
NOT_SUPPORTED,
133-
NOT_SUPPORTED,
134-
NOT_SUPPORTED,
135-
NOT_SUPPORTED,
124+
(void *)&dvr_df_null,
125+
(void *)&dvr_df_null,
126+
(void *)&dvr_df_null,
127+
(void *)&dvr_df_null,
128+
(void *)&dvr_df_null,
129+
(void *)&dvr_df_null,
130+
(void *)&dvr_df_null,
131+
(void *)&dvr_df_null,
132+
(void *)&dvr_df_null,
133+
(void *)&dvr_df_null,
134+
(void *)&dvr_df_null,
135+
(void *)&dvr_df_null,
136+
(void *)&dvr_df_null,
136137
(void *)&dvr_df_null_long,
137138
&dvr_df_devctl,
138-
NOT_SUPPORTED,
139-
NOT_SUPPORTED,
139+
(void *)&dvr_df_null,
140+
(void *)&dvr_df_null,
140141
&dvr_df_ioctl2,
141142
};
142143
char TEVENT_BUF[6144];
@@ -285,9 +286,14 @@ int dvr_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen,
285286
return -EINVAL;
286287
}
287288

289+
int dvr_df_null()
290+
{
291+
return -EUNSUP;
292+
}
293+
288294
s64 dvr_df_null_long()
289295
{
290-
return -134LL;
296+
return -EUNSUP;
291297
}
292298

293299
int dvrioctl2_rec_start(

iop/dvrp/dvrav/src/dvrav.c

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ extern int dvrav_df_exit(iomanX_iop_device_t *dev);
3232
extern int dvrav_df_ioctl(iomanX_iop_file_t *f, int cmd, void *param);
3333
extern int dvrav_df_devctl(iomanX_iop_file_t *a1, const char *name, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
3434
extern int dvrav_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
35+
extern int dvrav_df_null();
3536
extern s64 dvrav_df_null_long();
3637
extern int avioctl2_select_position(iomanX_iop_file_t *a1, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
3738
extern int avioctl2_get_position(iomanX_iop_file_t *a1, int cmd, void *arg, unsigned int arglen, void *buf, unsigned int buflen);
@@ -112,30 +113,30 @@ static iomanX_iop_device_ops_t DvrFuncTbl =
112113
{
113114
&dvrav_df_init,
114115
&dvrav_df_exit,
115-
NOT_SUPPORTED,
116-
NOT_SUPPORTED,
117-
NOT_SUPPORTED,
118-
NOT_SUPPORTED,
119-
NOT_SUPPORTED,
120-
NOT_SUPPORTED,
116+
(void *)&dvrav_df_null,
117+
(void *)&dvrav_df_null,
118+
(void *)&dvrav_df_null,
119+
(void *)&dvrav_df_null,
120+
(void *)&dvrav_df_null,
121+
(void *)&dvrav_df_null,
121122
&dvrav_df_ioctl,
122-
NOT_SUPPORTED,
123-
NOT_SUPPORTED,
124-
NOT_SUPPORTED,
125-
NOT_SUPPORTED,
126-
NOT_SUPPORTED,
127-
NOT_SUPPORTED,
128-
NOT_SUPPORTED,
129-
NOT_SUPPORTED,
130-
NOT_SUPPORTED,
131-
NOT_SUPPORTED,
132-
NOT_SUPPORTED,
133-
NOT_SUPPORTED,
134-
NOT_SUPPORTED,
123+
(void *)&dvrav_df_null,
124+
(void *)&dvrav_df_null,
125+
(void *)&dvrav_df_null,
126+
(void *)&dvrav_df_null,
127+
(void *)&dvrav_df_null,
128+
(void *)&dvrav_df_null,
129+
(void *)&dvrav_df_null,
130+
(void *)&dvrav_df_null,
131+
(void *)&dvrav_df_null,
132+
(void *)&dvrav_df_null,
133+
(void *)&dvrav_df_null,
134+
(void *)&dvrav_df_null,
135+
(void *)&dvrav_df_null,
135136
(void *)&dvrav_df_null_long,
136137
&dvrav_df_devctl,
137-
NOT_SUPPORTED,
138-
NOT_SUPPORTED,
138+
(void *)&dvrav_df_null,
139+
(void *)&dvrav_df_null,
139140
&dvrav_df_ioctl2,
140141
};
141142
static iomanX_iop_device_t DVRAV = {
@@ -283,9 +284,14 @@ int dvrav_df_ioctl2(iomanX_iop_file_t *f, int cmd, void *arg, unsigned int argle
283284
return -EINVAL;
284285
}
285286

287+
int dvrav_df_null()
288+
{
289+
return -EUNSUP;
290+
}
291+
286292
s64 dvrav_df_null_long()
287293
{
288-
return -134LL;
294+
return -EUNSUP;
289295
}
290296

291297
int avioctl2_get_tun_offset(

0 commit comments

Comments
 (0)