aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2004-08-01 20:14:04 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-08-01 20:14:04 -0700
commit93bcf57f63949f7d9328b8679a76d3c50b659260 (patch)
tree8bddce980547aa45e21233a07edf2534faef9cbe /drivers
parentb636665c715edf0520809c60a87f0932cfcb72eb (diff)
downloadhistory-93bcf57f63949f7d9328b8679a76d3c50b659260.tar.gz
[PATCH] DVB: "errno" undefined
Actually, the problem has its origin in my removal of all in-kernel syscalls (except execve, which is non-trivial) earlier this year. This change was blindly reverted by the maintainer, while at the same time the local errno variable was removed. See also http://linux.bkbits.net:8080/linux-2.5/hist/drivers/media/dvb/frontends/tda= 1004x.c This patch is the one that was already merged earlier. I'm now also removing the definitions for the kernel syscalls on i386 to make it harder to reintroduce them again. This was already done for ppc64, the others should probably follow. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/dvb/frontends/alps_tdlb7.c10
-rw-r--r--drivers/media/dvb/frontends/sp887x.c9
-rw-r--r--drivers/media/dvb/frontends/tda1004x.c10
-rw-r--r--drivers/net/wireless/prism54/isl_38xx.c2
4 files changed, 12 insertions, 19 deletions
diff --git a/drivers/media/dvb/frontends/alps_tdlb7.c b/drivers/media/dvb/frontends/alps_tdlb7.c
index 64d95f2f88c95b..cf165f2d576704 100644
--- a/drivers/media/dvb/frontends/alps_tdlb7.c
+++ b/drivers/media/dvb/frontends/alps_tdlb7.c
@@ -28,8 +28,6 @@
*/
-
-#define __KERNEL_SYSCALLS__
#include <linux/module.h>
#include <linux/init.h>
#include <linux/vmalloc.h>
@@ -151,13 +149,13 @@ static int sp8870_read_firmware_file (const char *fn, char **fp)
loff_t filesize;
char *dp;
- fd = open(fn, 0, 0);
+ fd = sys_open(fn, 0, 0);
if (fd == -1) {
printk("%s: unable to open '%s'.\n", __FUNCTION__, fn);
return -EIO;
}
- filesize = lseek(fd, 0L, 2);
+ filesize = sys_lseek(fd, 0L, 2);
if (filesize <= 0 || filesize < SP8870_FIRMWARE_OFFSET + SP8870_FIRMWARE_SIZE) {
printk("%s: firmware filesize to small '%s'\n", __FUNCTION__, fn);
sys_close(fd);
@@ -171,8 +169,8 @@ static int sp8870_read_firmware_file (const char *fn, char **fp)
return -EIO;
}
- lseek(fd, SP8870_FIRMWARE_OFFSET, 0);
- if (read(fd, dp, SP8870_FIRMWARE_SIZE) != SP8870_FIRMWARE_SIZE) {
+ sys_lseek(fd, SP8870_FIRMWARE_OFFSET, 0);
+ if (sys_read(fd, dp, SP8870_FIRMWARE_SIZE) != SP8870_FIRMWARE_SIZE) {
printk("%s: failed to read '%s'.\n",__FUNCTION__, fn);
vfree(dp);
sys_close(fd);
diff --git a/drivers/media/dvb/frontends/sp887x.c b/drivers/media/dvb/frontends/sp887x.c
index 3b3a73bb00d737..53ebf4a69b07e2 100644
--- a/drivers/media/dvb/frontends/sp887x.c
+++ b/drivers/media/dvb/frontends/sp887x.c
@@ -12,7 +12,6 @@
next 0x4000 loaded. This may change in future versions.
*/
-#define __KERNEL_SYSCALLS__
#include <linux/kernel.h>
#include <linux/vmalloc.h>
#include <linux/module.h>
@@ -211,13 +210,13 @@ int sp887x_initial_setup (struct dvb_frontend *fe)
// Load the firmware
set_fs(get_ds());
- fd = open(sp887x_firmware, 0, 0);
+ fd = sys_open(sp887x_firmware, 0, 0);
if (fd < 0) {
printk(KERN_WARNING "%s: Unable to open firmware %s\n", __FUNCTION__,
sp887x_firmware);
return -EIO;
}
- filesize = lseek(fd, 0L, 2);
+ filesize = sys_lseek(fd, 0L, 2);
if (filesize <= 0) {
printk(KERN_WARNING "%s: Firmware %s is empty\n", __FUNCTION__,
sp887x_firmware);
@@ -239,8 +238,8 @@ int sp887x_initial_setup (struct dvb_frontend *fe)
// read it!
// read the first 16384 bytes from the file
// ignore the first 10 bytes
- lseek(fd, 10, 0);
- if (read(fd, firmware, fw_size) != fw_size) {
+ sys_lseek(fd, 10, 0);
+ if (sys_read(fd, firmware, fw_size) != fw_size) {
printk(KERN_WARNING "%s: Failed to read firmware\n", __FUNCTION__);
vfree(firmware);
sys_close(fd);
diff --git a/drivers/media/dvb/frontends/tda1004x.c b/drivers/media/dvb/frontends/tda1004x.c
index 76a6027dbdb61a..28dc299a8cd5ad 100644
--- a/drivers/media/dvb/frontends/tda1004x.c
+++ b/drivers/media/dvb/frontends/tda1004x.c
@@ -32,7 +32,6 @@
*/
-#define __KERNEL_SYSCALLS__
#include <linux/kernel.h>
#include <linux/vmalloc.h>
#include <linux/module.h>
@@ -40,7 +39,6 @@
#include <linux/string.h>
#include <linux/slab.h>
#include <linux/fs.h>
-#include <linux/unistd.h>
#include <linux/fcntl.h>
#include <linux/errno.h>
#include <linux/syscalls.h>
@@ -399,13 +397,13 @@ static int tda1004x_fwupload(struct dvb_i2c_bus *i2c, struct tda1004x_state *tda
// Load the firmware
set_fs(get_ds());
- fd = open(tda1004x_firmware, 0, 0);
+ fd = sys_open(tda1004x_firmware, 0, 0);
if (fd < 0) {
printk("%s: Unable to open firmware %s\n", __FUNCTION__,
tda1004x_firmware);
return -EIO;
}
- filesize = lseek(fd, 0L, 2);
+ filesize = sys_lseek(fd, 0L, 2);
if (filesize <= 0) {
printk("%s: Firmware %s is empty\n", __FUNCTION__,
tda1004x_firmware);
@@ -436,8 +434,8 @@ static int tda1004x_fwupload(struct dvb_i2c_bus *i2c, struct tda1004x_state *tda
}
// read it!
- lseek(fd, fw_offset, 0);
- if (read(fd, firmware, fw_size) != fw_size) {
+ sys_lseek(fd, fw_offset, 0);
+ if (sys_read(fd, firmware, fw_size) != fw_size) {
printk("%s: Failed to read firmware\n", __FUNCTION__);
vfree(firmware);
sys_close(fd);
diff --git a/drivers/net/wireless/prism54/isl_38xx.c b/drivers/net/wireless/prism54/isl_38xx.c
index dd50660379043a..3ee31021f1b054 100644
--- a/drivers/net/wireless/prism54/isl_38xx.c
+++ b/drivers/net/wireless/prism54/isl_38xx.c
@@ -18,8 +18,6 @@
*
*/
-#define __KERNEL_SYSCALLS__
-
#include <linux/version.h>
#include <linux/module.h>
#include <linux/types.h>