1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
|
// SPDX-License-Identifier: GPL-2.0
// Generated by xdrgen. Manual edits will be lost.
// XDR specification file: ../../Documentation/sunrpc/xdr/nlm4.x
// XDR specification modification time: Thu Dec 25 13:10:19 2025
#include <linux/sunrpc/svc.h>
#include "nlm4xdr_gen.h"
static bool __maybe_unused
xdrgen_decode_netobj(struct xdr_stream *xdr, netobj *ptr)
{
return xdrgen_decode_opaque(xdr, ptr, MAXNETOBJ_SZ);
}
static bool __maybe_unused
xdrgen_decode_fsh4_mode(struct xdr_stream *xdr, fsh4_mode *ptr)
{
u32 val;
if (xdr_stream_decode_u32(xdr, &val) < 0)
return false;
*ptr = val;
return true;
}
static bool __maybe_unused
xdrgen_decode_fsh4_access(struct xdr_stream *xdr, fsh4_access *ptr)
{
u32 val;
if (xdr_stream_decode_u32(xdr, &val) < 0)
return false;
*ptr = val;
return true;
}
static bool __maybe_unused
xdrgen_decode_uint64(struct xdr_stream *xdr, uint64 *ptr)
{
return xdrgen_decode_unsigned_hyper(xdr, ptr);
}
static bool __maybe_unused
xdrgen_decode_int64(struct xdr_stream *xdr, int64 *ptr)
{
return xdrgen_decode_hyper(xdr, ptr);
}
static bool __maybe_unused
xdrgen_decode_uint32(struct xdr_stream *xdr, uint32 *ptr)
{
return xdrgen_decode_unsigned_long(xdr, ptr);
}
static bool __maybe_unused
xdrgen_decode_int32(struct xdr_stream *xdr, int32 *ptr)
{
return xdrgen_decode_long(xdr, ptr);
}
static bool __maybe_unused
xdrgen_decode_nlm4_stats(struct xdr_stream *xdr, nlm4_stats *ptr)
{
return xdr_stream_decode_be32(xdr, ptr) == 0;
}
static bool __maybe_unused
xdrgen_decode_nlm4_holder(struct xdr_stream *xdr, struct nlm4_holder *ptr)
{
if (!xdrgen_decode_bool(xdr, &ptr->exclusive))
return false;
if (!xdrgen_decode_int32(xdr, &ptr->svid))
return false;
if (!xdrgen_decode_netobj(xdr, &ptr->oh))
return false;
if (!xdrgen_decode_uint64(xdr, &ptr->l_offset))
return false;
if (!xdrgen_decode_uint64(xdr, &ptr->l_len))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_testrply(struct xdr_stream *xdr, struct nlm4_testrply *ptr)
{
if (!xdrgen_decode_nlm4_stats(xdr, &ptr->stat))
return false;
switch (ptr->stat) {
case __constant_cpu_to_be32(NLM4_DENIED):
if (!xdrgen_decode_nlm4_holder(xdr, &ptr->u.holder))
return false;
break;
default:
break;
}
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_stat(struct xdr_stream *xdr, struct nlm4_stat *ptr)
{
if (!xdrgen_decode_nlm4_stats(xdr, &ptr->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_res(struct xdr_stream *xdr, struct nlm4_res *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_nlm4_stat(xdr, &ptr->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_testres(struct xdr_stream *xdr, struct nlm4_testres *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_nlm4_testrply(xdr, &ptr->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_lock(struct xdr_stream *xdr, struct nlm4_lock *ptr)
{
if (!xdrgen_decode_string(xdr, (string *)ptr, LM_MAXSTRLEN))
return false;
if (!xdrgen_decode_netobj(xdr, &ptr->fh))
return false;
if (!xdrgen_decode_netobj(xdr, &ptr->oh))
return false;
if (!xdrgen_decode_int32(xdr, &ptr->svid))
return false;
if (!xdrgen_decode_uint64(xdr, &ptr->l_offset))
return false;
if (!xdrgen_decode_uint64(xdr, &ptr->l_len))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_lockargs(struct xdr_stream *xdr, struct nlm4_lockargs *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->block))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->exclusive))
return false;
if (!xdrgen_decode_nlm4_lock(xdr, &ptr->alock))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->reclaim))
return false;
if (!xdrgen_decode_int32(xdr, &ptr->state))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_cancargs(struct xdr_stream *xdr, struct nlm4_cancargs *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->block))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->exclusive))
return false;
if (!xdrgen_decode_nlm4_lock(xdr, &ptr->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_testargs(struct xdr_stream *xdr, struct nlm4_testargs *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->exclusive))
return false;
if (!xdrgen_decode_nlm4_lock(xdr, &ptr->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_unlockargs(struct xdr_stream *xdr, struct nlm4_unlockargs *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_nlm4_lock(xdr, &ptr->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_share(struct xdr_stream *xdr, struct nlm4_share *ptr)
{
if (!xdrgen_decode_string(xdr, (string *)ptr, LM_MAXSTRLEN))
return false;
if (!xdrgen_decode_netobj(xdr, &ptr->fh))
return false;
if (!xdrgen_decode_netobj(xdr, &ptr->oh))
return false;
if (!xdrgen_decode_fsh4_mode(xdr, &ptr->mode))
return false;
if (!xdrgen_decode_fsh4_access(xdr, &ptr->access))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_shareargs(struct xdr_stream *xdr, struct nlm4_shareargs *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_nlm4_share(xdr, &ptr->share))
return false;
if (!xdrgen_decode_bool(xdr, &ptr->reclaim))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_shareres(struct xdr_stream *xdr, struct nlm4_shareres *ptr)
{
if (!xdrgen_decode_netobj(xdr, &ptr->cookie))
return false;
if (!xdrgen_decode_nlm4_stats(xdr, &ptr->stat))
return false;
if (!xdrgen_decode_int32(xdr, &ptr->sequence))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_notify(struct xdr_stream *xdr, struct nlm4_notify *ptr)
{
if (!xdrgen_decode_string(xdr, (string *)ptr, LM_MAXNAMELEN))
return false;
if (!xdrgen_decode_int32(xdr, &ptr->state))
return false;
return true;
}
static bool __maybe_unused
xdrgen_decode_nlm4_notifyargs(struct xdr_stream *xdr, struct nlm4_notifyargs *ptr)
{
if (!xdrgen_decode_nlm4_notify(xdr, &ptr->notify))
return false;
if (xdr_stream_decode_opaque_fixed(xdr, ptr->private, SM_PRIV_SIZE) < 0)
return false;
return true;
}
/**
* nlm4_svc_decode_void - Decode a void argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_void(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
return xdrgen_decode_void(xdr);
}
/**
* nlm4_svc_decode_nlm4_testargs - Decode a nlm4_testargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_testargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_testargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_testargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_lockargs - Decode a nlm4_lockargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_lockargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_lockargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_lockargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_cancargs - Decode a nlm4_cancargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_cancargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_cancargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_cancargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_unlockargs - Decode a nlm4_unlockargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_unlockargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_unlockargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_unlockargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_testres - Decode a nlm4_testres argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_testres(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_testres *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_testres(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_res - Decode a nlm4_res argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_res(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_res *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_res(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_notifyargs - Decode a nlm4_notifyargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_notifyargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_notifyargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_notifyargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_shareargs - Decode a nlm4_shareargs argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_shareargs(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_shareargs *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_shareargs(xdr, argp);
}
/**
* nlm4_svc_decode_nlm4_notify - Decode a nlm4_notify argument
* @rqstp: RPC transaction context
* @xdr: source XDR data stream
*
* Return values:
* %true: procedure arguments decoded successfully
* %false: decode failed
*/
bool nlm4_svc_decode_nlm4_notify(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_notify *argp = rqstp->rq_argp;
return xdrgen_decode_nlm4_notify(xdr, argp);
}
static bool __maybe_unused
xdrgen_encode_netobj(struct xdr_stream *xdr, const netobj value)
{
return xdr_stream_encode_opaque(xdr, value.data, value.len) >= 0;
}
static bool __maybe_unused
xdrgen_encode_fsh4_mode(struct xdr_stream *xdr, fsh4_mode value)
{
return xdr_stream_encode_u32(xdr, value) == XDR_UNIT;
}
static bool __maybe_unused
xdrgen_encode_fsh4_access(struct xdr_stream *xdr, fsh4_access value)
{
return xdr_stream_encode_u32(xdr, value) == XDR_UNIT;
}
static bool __maybe_unused
xdrgen_encode_uint64(struct xdr_stream *xdr, const uint64 value)
{
return xdrgen_encode_unsigned_hyper(xdr, value);
}
static bool __maybe_unused
xdrgen_encode_int64(struct xdr_stream *xdr, const int64 value)
{
return xdrgen_encode_hyper(xdr, value);
}
static bool __maybe_unused
xdrgen_encode_uint32(struct xdr_stream *xdr, const uint32 value)
{
return xdrgen_encode_unsigned_long(xdr, value);
}
static bool __maybe_unused
xdrgen_encode_int32(struct xdr_stream *xdr, const int32 value)
{
return xdrgen_encode_long(xdr, value);
}
static bool __maybe_unused
xdrgen_encode_nlm4_stats(struct xdr_stream *xdr, nlm4_stats value)
{
return xdr_stream_encode_be32(xdr, value) == XDR_UNIT;
}
static bool __maybe_unused
xdrgen_encode_nlm4_holder(struct xdr_stream *xdr, const struct nlm4_holder *value)
{
if (!xdrgen_encode_bool(xdr, value->exclusive))
return false;
if (!xdrgen_encode_int32(xdr, value->svid))
return false;
if (!xdrgen_encode_netobj(xdr, value->oh))
return false;
if (!xdrgen_encode_uint64(xdr, value->l_offset))
return false;
if (!xdrgen_encode_uint64(xdr, value->l_len))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_testrply(struct xdr_stream *xdr, const struct nlm4_testrply *ptr)
{
if (!xdrgen_encode_nlm4_stats(xdr, ptr->stat))
return false;
switch (ptr->stat) {
case __constant_cpu_to_be32(NLM4_DENIED):
if (!xdrgen_encode_nlm4_holder(xdr, &ptr->u.holder))
return false;
break;
default:
break;
}
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_stat(struct xdr_stream *xdr, const struct nlm4_stat *value)
{
if (!xdrgen_encode_nlm4_stats(xdr, value->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_res(struct xdr_stream *xdr, const struct nlm4_res *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_nlm4_stat(xdr, &value->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_testres(struct xdr_stream *xdr, const struct nlm4_testres *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_nlm4_testrply(xdr, &value->stat))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_lock(struct xdr_stream *xdr, const struct nlm4_lock *value)
{
if (value->caller_name.len > LM_MAXSTRLEN)
return false;
if (xdr_stream_encode_opaque(xdr, value->caller_name.data, value->caller_name.len) < 0)
return false;
if (!xdrgen_encode_netobj(xdr, value->fh))
return false;
if (!xdrgen_encode_netobj(xdr, value->oh))
return false;
if (!xdrgen_encode_int32(xdr, value->svid))
return false;
if (!xdrgen_encode_uint64(xdr, value->l_offset))
return false;
if (!xdrgen_encode_uint64(xdr, value->l_len))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_lockargs(struct xdr_stream *xdr, const struct nlm4_lockargs *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_bool(xdr, value->block))
return false;
if (!xdrgen_encode_bool(xdr, value->exclusive))
return false;
if (!xdrgen_encode_nlm4_lock(xdr, &value->alock))
return false;
if (!xdrgen_encode_bool(xdr, value->reclaim))
return false;
if (!xdrgen_encode_int32(xdr, value->state))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_cancargs(struct xdr_stream *xdr, const struct nlm4_cancargs *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_bool(xdr, value->block))
return false;
if (!xdrgen_encode_bool(xdr, value->exclusive))
return false;
if (!xdrgen_encode_nlm4_lock(xdr, &value->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_testargs(struct xdr_stream *xdr, const struct nlm4_testargs *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_bool(xdr, value->exclusive))
return false;
if (!xdrgen_encode_nlm4_lock(xdr, &value->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_unlockargs(struct xdr_stream *xdr, const struct nlm4_unlockargs *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_nlm4_lock(xdr, &value->alock))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_share(struct xdr_stream *xdr, const struct nlm4_share *value)
{
if (value->caller_name.len > LM_MAXSTRLEN)
return false;
if (xdr_stream_encode_opaque(xdr, value->caller_name.data, value->caller_name.len) < 0)
return false;
if (!xdrgen_encode_netobj(xdr, value->fh))
return false;
if (!xdrgen_encode_netobj(xdr, value->oh))
return false;
if (!xdrgen_encode_fsh4_mode(xdr, value->mode))
return false;
if (!xdrgen_encode_fsh4_access(xdr, value->access))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_shareargs(struct xdr_stream *xdr, const struct nlm4_shareargs *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_nlm4_share(xdr, &value->share))
return false;
if (!xdrgen_encode_bool(xdr, value->reclaim))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_shareres(struct xdr_stream *xdr, const struct nlm4_shareres *value)
{
if (!xdrgen_encode_netobj(xdr, value->cookie))
return false;
if (!xdrgen_encode_nlm4_stats(xdr, value->stat))
return false;
if (!xdrgen_encode_int32(xdr, value->sequence))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_notify(struct xdr_stream *xdr, const struct nlm4_notify *value)
{
if (value->name.len > LM_MAXNAMELEN)
return false;
if (xdr_stream_encode_opaque(xdr, value->name.data, value->name.len) < 0)
return false;
if (!xdrgen_encode_int32(xdr, value->state))
return false;
return true;
}
static bool __maybe_unused
xdrgen_encode_nlm4_notifyargs(struct xdr_stream *xdr, const struct nlm4_notifyargs *value)
{
if (!xdrgen_encode_nlm4_notify(xdr, &value->notify))
return false;
if (xdr_stream_encode_opaque_fixed(xdr, value->private, SM_PRIV_SIZE) < 0)
return false;
return true;
}
/**
* nlm4_svc_encode_void - Encode a void result
* @rqstp: RPC transaction context
* @xdr: target XDR data stream
*
* Return values:
* %true: procedure results encoded successfully
* %false: encode failed
*/
bool nlm4_svc_encode_void(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
return xdrgen_encode_void(xdr);
}
/**
* nlm4_svc_encode_nlm4_testres - Encode a nlm4_testres result
* @rqstp: RPC transaction context
* @xdr: target XDR data stream
*
* Return values:
* %true: procedure results encoded successfully
* %false: encode failed
*/
bool nlm4_svc_encode_nlm4_testres(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_testres *resp = rqstp->rq_resp;
return xdrgen_encode_nlm4_testres(xdr, resp);
}
/**
* nlm4_svc_encode_nlm4_res - Encode a nlm4_res result
* @rqstp: RPC transaction context
* @xdr: target XDR data stream
*
* Return values:
* %true: procedure results encoded successfully
* %false: encode failed
*/
bool nlm4_svc_encode_nlm4_res(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_res *resp = rqstp->rq_resp;
return xdrgen_encode_nlm4_res(xdr, resp);
}
/**
* nlm4_svc_encode_nlm4_shareres - Encode a nlm4_shareres result
* @rqstp: RPC transaction context
* @xdr: target XDR data stream
*
* Return values:
* %true: procedure results encoded successfully
* %false: encode failed
*/
bool nlm4_svc_encode_nlm4_shareres(struct svc_rqst *rqstp, struct xdr_stream *xdr)
{
struct nlm4_shareres *resp = rqstp->rq_resp;
return xdrgen_encode_nlm4_shareres(xdr, resp);
}
|