Skip to content

Commit 092e0e7

Browse files
committed
Merge branch 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl
* 'llseek' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl: vfs: make no_llseek the default vfs: don't use BKL in default_llseek llseek: automatically add .llseek fop libfs: use generic_file_llseek for simple_attr mac80211: disallow seeks in minstrel debug code lirc: make chardev nonseekable viotape: use noop_llseek raw: use explicit llseek file operations ibmasmfs: use generic_file_llseek spufs: use llseek in all file operations arm/omap: use generic_file_llseek in iommu_debug lkdtm: use generic_file_llseek in debugfs net/wireless: use generic_file_llseek in debugfs drm: use noop_llseek
2 parents 79f14b7 + 776c163 commit 092e0e7

File tree

370 files changed

+601
-77
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

370 files changed

+601
-77
lines changed

Documentation/DocBook/drm.tmpl

+1
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,7 @@
136136
#ifdef CONFIG_COMPAT
137137
.compat_ioctl = i915_compat_ioctl,
138138
#endif
139+
.llseek = noop_llseek,
139140
},
140141
.pci_driver = {
141142
.name = DRIVER_NAME,

arch/arm/kernel/etm.c

+1
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,7 @@ static const struct file_operations etb_fops = {
329329
.read = etb_read,
330330
.open = etb_open,
331331
.release = etb_release,
332+
.llseek = no_llseek,
332333
};
333334

334335
static struct miscdevice etb_miscdev = {

arch/arm/mach-msm/last_radio_log.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ static ssize_t last_radio_log_read(struct file *file, char __user *buf,
4848
}
4949

5050
static struct file_operations last_radio_log_fops = {
51-
.read = last_radio_log_read
51+
.read = last_radio_log_read,
52+
.llseek = default_llseek,
5253
};
5354

5455
void msm_init_last_radio_log(struct module *owner)

arch/arm/mach-msm/smd_debug.c

+1
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,7 @@ static int debug_open(struct inode *inode, struct file *file)
212212
static const struct file_operations debug_ops = {
213213
.read = debug_read,
214214
.open = debug_open,
215+
.llseek = default_llseek,
215216
};
216217

217218
static void debug_create(const char *name, mode_t mode,

arch/arm/plat-mxc/audmux-v2.c

+1
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,7 @@ static ssize_t audmux_read_file(struct file *file, char __user *user_buf,
137137
static const struct file_operations audmux_debugfs_fops = {
138138
.open = audmux_open_file,
139139
.read = audmux_read_file,
140+
.llseek = default_llseek,
140141
};
141142

142143
static void audmux_debugfs_init(void)

arch/arm/plat-omap/iommu-debug.c

+2
Original file line numberDiff line numberDiff line change
@@ -328,12 +328,14 @@ static int debug_open_generic(struct inode *inode, struct file *file)
328328
.open = debug_open_generic, \
329329
.read = debug_read_##name, \
330330
.write = debug_write_##name, \
331+
.llseek = generic_file_llseek, \
331332
};
332333

333334
#define DEBUG_FOPS_RO(name) \
334335
static const struct file_operations debug_##name##_fops = { \
335336
.open = debug_open_generic, \
336337
.read = debug_read_##name, \
338+
.llseek = generic_file_llseek, \
337339
};
338340

339341
DEBUG_FOPS_RO(ver);

arch/avr32/boards/mimc200/fram.c

+1
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ static int fram_mmap(struct file *filp, struct vm_area_struct *vma)
4141
static const struct file_operations fram_fops = {
4242
.owner = THIS_MODULE,
4343
.mmap = fram_mmap,
44+
.llseek = noop_llseek,
4445
};
4546

4647
#define FRAM_MINOR 0

arch/blackfin/kernel/kgdb_test.c

+1
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ static const struct file_operations kgdb_test_proc_fops = {
8888
.owner = THIS_MODULE,
8989
.read = kgdb_test_proc_read,
9090
.write = kgdb_test_proc_write,
91+
.llseek = noop_llseek,
9192
};
9293

9394
static int __init kgdbtest_init(void)

arch/blackfin/mach-bf561/coreb.c

+1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ coreb_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
5151
static const struct file_operations coreb_fops = {
5252
.owner = THIS_MODULE,
5353
.unlocked_ioctl = coreb_ioctl,
54+
.llseek = noop_llseek,
5455
};
5556

5657
static struct miscdevice coreb_dev = {

arch/cris/arch-v10/drivers/ds1302.c

+1
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,7 @@ print_rtc_status(void)
388388
static const struct file_operations rtc_fops = {
389389
.owner = THIS_MODULE,
390390
.unlocked_ioctl = rtc_unlocked_ioctl,
391+
.llseek = noop_llseek,
391392
};
392393

393394
/* Probe for the chip by writing something to its RAM and try reading it back. */

arch/cris/arch-v10/drivers/gpio.c

+1
Original file line numberDiff line numberDiff line change
@@ -745,6 +745,7 @@ static const struct file_operations gpio_fops = {
745745
.write = gpio_write,
746746
.open = gpio_open,
747747
.release = gpio_release,
748+
.llseek = noop_llseek,
748749
};
749750

750751
static void ioif_watcher(const unsigned int gpio_in_available,

arch/cris/arch-v10/drivers/i2c.c

+1
Original file line numberDiff line numberDiff line change
@@ -617,6 +617,7 @@ static const struct file_operations i2c_fops = {
617617
.unlocked_ioctl = i2c_ioctl,
618618
.open = i2c_open,
619619
.release = i2c_release,
620+
.llseek = noop_llseek,
620621
};
621622

622623
int __init

arch/cris/arch-v10/drivers/pcf8563.c

+1
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ static int voltage_low;
6464
static const struct file_operations pcf8563_fops = {
6565
.owner = THIS_MODULE,
6666
.unlocked_ioctl = pcf8563_unlocked_ioctl,
67+
.llseek = noop_llseek,
6768
};
6869

6970
unsigned char

arch/cris/arch-v10/drivers/sync_serial.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,8 @@ static const struct file_operations sync_serial_fops = {
251251
.poll = sync_serial_poll,
252252
.unlocked_ioctl = sync_serial_ioctl,
253253
.open = sync_serial_open,
254-
.release = sync_serial_release
254+
.release = sync_serial_release,
255+
.llseek = noop_llseek,
255256
};
256257

257258
static int __init etrax_sync_serial_init(void)

arch/cris/arch-v32/drivers/cryptocop.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,8 @@ const struct file_operations cryptocop_fops = {
281281
.owner = THIS_MODULE,
282282
.open = cryptocop_open,
283283
.release = cryptocop_release,
284-
.unlocked_ioctl = cryptocop_ioctl
284+
.unlocked_ioctl = cryptocop_ioctl,
285+
.llseek = noop_llseek,
285286
};
286287

287288

arch/cris/arch-v32/drivers/i2c.c

+1
Original file line numberDiff line numberDiff line change
@@ -698,6 +698,7 @@ static const struct file_operations i2c_fops = {
698698
.unlocked_ioctl = i2c_ioctl,
699699
.open = i2c_open,
700700
.release = i2c_release,
701+
.llseek = noop_llseek,
701702
};
702703

703704
static int __init i2c_init(void)

arch/cris/arch-v32/drivers/mach-a3/gpio.c

+1
Original file line numberDiff line numberDiff line change
@@ -894,6 +894,7 @@ static const struct file_operations gpio_fops = {
894894
.write = gpio_write,
895895
.open = gpio_open,
896896
.release = gpio_release,
897+
.llseek = noop_llseek,
897898
};
898899

899900
#ifdef CONFIG_ETRAX_VIRTUAL_GPIO

arch/cris/arch-v32/drivers/mach-fs/gpio.c

+1
Original file line numberDiff line numberDiff line change
@@ -871,6 +871,7 @@ static const struct file_operations gpio_fops = {
871871
.write = gpio_write,
872872
.open = gpio_open,
873873
.release = gpio_release,
874+
.llseek = noop_llseek,
874875
};
875876

876877
#ifdef CONFIG_ETRAX_VIRTUAL_GPIO

arch/cris/arch-v32/drivers/pcf8563.c

+1
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ static int voltage_low;
6060
static const struct file_operations pcf8563_fops = {
6161
.owner = THIS_MODULE,
6262
.unlocked_ioctl = pcf8563_unlocked_ioctl,
63+
.llseek = noop_llseek,
6364
};
6465

6566
unsigned char

arch/cris/arch-v32/drivers/sync_serial.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,8 @@ static const struct file_operations sync_serial_fops = {
248248
.poll = sync_serial_poll,
249249
.unlocked_ioctl = sync_serial_ioctl,
250250
.open = sync_serial_open,
251-
.release = sync_serial_release
251+
.release = sync_serial_release,
252+
.llseek = noop_llseek,
252253
};
253254

254255
static int __init etrax_sync_serial_init(void)

arch/cris/kernel/profile.c

+1
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ write_cris_profile(struct file *file, const char __user *buf,
5959
static const struct file_operations cris_proc_profile_operations = {
6060
.read = read_cris_profile,
6161
.write = write_cris_profile,
62+
.llseek = default_llseek,
6263
};
6364

6465
static int __init init_cris_profile(void)

arch/ia64/kernel/salinfo.c

+2
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,7 @@ salinfo_event_read(struct file *file, char __user *buffer, size_t count, loff_t
354354
static const struct file_operations salinfo_event_fops = {
355355
.open = salinfo_event_open,
356356
.read = salinfo_event_read,
357+
.llseek = noop_llseek,
357358
};
358359

359360
static int
@@ -571,6 +572,7 @@ static const struct file_operations salinfo_data_fops = {
571572
.release = salinfo_log_release,
572573
.read = salinfo_log_read,
573574
.write = salinfo_log_write,
575+
.llseek = default_llseek,
574576
};
575577

576578
static int __cpuinit

arch/ia64/sn/kernel/sn2/sn_hwperf.c

+1
Original file line numberDiff line numberDiff line change
@@ -860,6 +860,7 @@ static long sn_hwperf_ioctl(struct file *fp, u32 op, unsigned long arg)
860860

861861
static const struct file_operations sn_hwperf_fops = {
862862
.unlocked_ioctl = sn_hwperf_ioctl,
863+
.llseek = noop_llseek,
863864
};
864865

865866
static struct miscdevice sn_hwperf_dev = {

arch/m68k/bvme6000/rtc.c

+1
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ static const struct file_operations rtc_fops = {
155155
.unlocked_ioctl = rtc_ioctl,
156156
.open = rtc_open,
157157
.release = rtc_release,
158+
.llseek = noop_llseek,
158159
};
159160

160161
static struct miscdevice rtc_dev = {

arch/m68k/mvme16x/rtc.c

+1
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ static const struct file_operations rtc_fops = {
144144
.unlocked_ioctl = rtc_ioctl,
145145
.open = rtc_open,
146146
.release = rtc_release,
147+
.llseek = noop_llseek,
147148
};
148149

149150
static struct miscdevice rtc_dev=

arch/mips/kernel/rtlx.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,8 @@ static const struct file_operations rtlx_fops = {
468468
.release = file_release,
469469
.write = file_write,
470470
.read = file_read,
471-
.poll = file_poll
471+
.poll = file_poll,
472+
.llseek = noop_llseek,
472473
};
473474

474475
static struct irqaction rtlx_irq = {

arch/mips/kernel/vpe.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -1192,7 +1192,8 @@ static const struct file_operations vpe_fops = {
11921192
.owner = THIS_MODULE,
11931193
.open = vpe_open,
11941194
.release = vpe_release,
1195-
.write = vpe_write
1195+
.write = vpe_write,
1196+
.llseek = noop_llseek,
11961197
};
11971198

11981199
/* module wrapper entry points */

arch/mips/sibyte/common/sb_tbprof.c

+1
Original file line numberDiff line numberDiff line change
@@ -545,6 +545,7 @@ static const struct file_operations sbprof_tb_fops = {
545545
.unlocked_ioctl = sbprof_tb_ioctl,
546546
.compat_ioctl = sbprof_tb_ioctl,
547547
.mmap = NULL,
548+
.llseek = default_llseek,
548549
};
549550

550551
static struct class *tb_class;

arch/powerpc/kernel/lparcfg.c

+1
Original file line numberDiff line numberDiff line change
@@ -780,6 +780,7 @@ static const struct file_operations lparcfg_fops = {
780780
.write = lparcfg_write,
781781
.open = lparcfg_open,
782782
.release = single_release,
783+
.llseek = seq_lseek,
783784
};
784785

785786
static int __init lparcfg_init(void)

arch/powerpc/kernel/rtas_flash.c

+3
Original file line numberDiff line numberDiff line change
@@ -716,6 +716,7 @@ static const struct file_operations rtas_flash_operations = {
716716
.write = rtas_flash_write,
717717
.open = rtas_excl_open,
718718
.release = rtas_flash_release,
719+
.llseek = default_llseek,
719720
};
720721

721722
static const struct file_operations manage_flash_operations = {
@@ -724,6 +725,7 @@ static const struct file_operations manage_flash_operations = {
724725
.write = manage_flash_write,
725726
.open = rtas_excl_open,
726727
.release = rtas_excl_release,
728+
.llseek = default_llseek,
727729
};
728730

729731
static const struct file_operations validate_flash_operations = {
@@ -732,6 +734,7 @@ static const struct file_operations validate_flash_operations = {
732734
.write = validate_flash_write,
733735
.open = rtas_excl_open,
734736
.release = validate_flash_release,
737+
.llseek = default_llseek,
735738
};
736739

737740
static int __init rtas_flash_init(void)

arch/powerpc/kernel/rtasd.c

+1
Original file line numberDiff line numberDiff line change
@@ -354,6 +354,7 @@ static const struct file_operations proc_rtas_log_operations = {
354354
.poll = rtas_log_poll,
355355
.open = rtas_log_open,
356356
.release = rtas_log_release,
357+
.llseek = noop_llseek,
357358
};
358359

359360
static int enable_surveillance(int timeout)

arch/powerpc/platforms/iseries/mf.c

+1
Original file line numberDiff line numberDiff line change
@@ -1249,6 +1249,7 @@ static ssize_t proc_mf_change_vmlinux(struct file *file,
12491249

12501250
static const struct file_operations proc_vmlinux_operations = {
12511251
.write = proc_mf_change_vmlinux,
1252+
.llseek = default_llseek,
12521253
};
12531254

12541255
static int __init mf_proc_init(void)

arch/powerpc/platforms/pseries/reconfig.c

+2-1
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,8 @@ static ssize_t ofdt_write(struct file *file, const char __user *buf, size_t coun
539539
}
540540

541541
static const struct file_operations ofdt_fops = {
542-
.write = ofdt_write
542+
.write = ofdt_write,
543+
.llseek = noop_llseek,
543544
};
544545

545546
/* create /proc/powerpc/ofdt write-only by root */

arch/powerpc/platforms/pseries/scanlog.c

+1
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,7 @@ const struct file_operations scanlog_fops = {
170170
.write = scanlog_write,
171171
.open = scanlog_open,
172172
.release = scanlog_release,
173+
.llseek = noop_llseek,
173174
};
174175

175176
static int __init scanlog_init(void)

arch/s390/crypto/prng.c

+1
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ static const struct file_operations prng_fops = {
152152
.open = &prng_open,
153153
.release = NULL,
154154
.read = &prng_read,
155+
.llseek = noop_llseek,
155156
};
156157

157158
static struct miscdevice prng_dev = {

arch/s390/hypfs/hypfs_diag.c

+1
Original file line numberDiff line numberDiff line change
@@ -618,6 +618,7 @@ static const struct file_operations dbfs_d204_ops = {
618618
.open = dbfs_d204_open,
619619
.read = dbfs_d204_read,
620620
.release = dbfs_d204_release,
621+
.llseek = no_llseek,
621622
};
622623

623624
static int hypfs_dbfs_init(void)

arch/s390/hypfs/hypfs_vm.c

+1
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,7 @@ static const struct file_operations dbfs_d2fc_ops = {
275275
.open = dbfs_d2fc_open,
276276
.read = dbfs_d2fc_read,
277277
.release = dbfs_d2fc_release,
278+
.llseek = no_llseek,
278279
};
279280

280281
int hypfs_vm_init(void)

arch/s390/hypfs/inode.c

+1
Original file line numberDiff line numberDiff line change
@@ -449,6 +449,7 @@ static const struct file_operations hypfs_file_ops = {
449449
.write = do_sync_write,
450450
.aio_read = hypfs_aio_read,
451451
.aio_write = hypfs_aio_write,
452+
.llseek = no_llseek,
452453
};
453454

454455
static struct file_system_type hypfs_type = {

arch/s390/kernel/debug.c

+1
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,7 @@ static const struct file_operations debug_file_ops = {
174174
.write = debug_input,
175175
.open = debug_open,
176176
.release = debug_close,
177+
.llseek = no_llseek,
177178
};
178179

179180
static struct dentry *debug_debugfs_root_entry;

arch/sh/boards/mach-landisk/gio.c

+1
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,7 @@ static const struct file_operations gio_fops = {
128128
.open = gio_open, /* open */
129129
.release = gio_close, /* release */
130130
.unlocked_ioctl = gio_ioctl,
131+
.llseek = noop_llseek,
131132
};
132133

133134
static int __init gio_init(void)

arch/sparc/kernel/apc.c

+1
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@ static const struct file_operations apc_fops = {
132132
.unlocked_ioctl = apc_ioctl,
133133
.open = apc_open,
134134
.release = apc_release,
135+
.llseek = noop_llseek,
135136
};
136137

137138
static struct miscdevice apc_miscdev = { APC_MINOR, APC_DEVNAME, &apc_fops };

arch/sparc/kernel/mdesc.c

+1
Original file line numberDiff line numberDiff line change
@@ -890,6 +890,7 @@ static ssize_t mdesc_read(struct file *file, char __user *buf,
890890
static const struct file_operations mdesc_fops = {
891891
.read = mdesc_read,
892892
.owner = THIS_MODULE,
893+
.llseek = noop_llseek,
893894
};
894895

895896
static struct miscdevice mdesc_misc = {

arch/tile/kernel/hardwall.c

+1
Original file line numberDiff line numberDiff line change
@@ -774,6 +774,7 @@ static const struct file_operations dev_hardwall_fops = {
774774
#endif
775775
.flush = hardwall_flush,
776776
.release = hardwall_release,
777+
.llseek = noop_llseek,
777778
};
778779

779780
static struct cdev hardwall_dev;

arch/um/drivers/harddog_kern.c

+1
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ static const struct file_operations harddog_fops = {
167167
.unlocked_ioctl = harddog_ioctl,
168168
.open = harddog_open,
169169
.release = harddog_release,
170+
.llseek = no_llseek,
170171
};
171172

172173
static struct miscdevice harddog_miscdev = {

0 commit comments

Comments
 (0)