From: Juan Quintela <quintela@mandrakesoft.com>
To: Ralf Baechle <ralf@linux-mips.org>, mipslist <linux-mips@linux-mips.org>
Subject: [PATCH]: Make IP22 compile without newport
Date: Thu, 27 Mar 2003 03:52:05 +0100 [thread overview]
Message-ID: <m2u1dped2i.fsf@mandrakesoft.com> (raw)
Hi
Make sgi-ip22 compile without newport support. Users that don't have
a graphic card (or an unsupported graphics card) don't need it.
Once there, I remove a duplicated call to gfx_register().
TODO: shmiq.o can also be removed when you don't have setup
CONFIG_NEWPORT_CONSOLE or CONFIG_NEWPORT_GFX. But they have an
incestous relation with this file.
Later, Juan.
build/arch/mips/sgi-ip22/ip22-setup.c | 3 ++-
build/drivers/char/misc.c | 5 -----
build/drivers/sgi/char/Makefile | 5 +++--
build/drivers/sgi/char/shmiq.c | 11 +++++++++--
4 files changed, 14 insertions(+), 10 deletions(-)
diff -puN build/arch/mips/sgi-ip22/ip22-setup.c~newport build/arch/mips/sgi-ip22/ip22-setup.c
--- 24/build/arch/mips/sgi-ip22/ip22-setup.c~newport 2003-03-26 17:53:58.000000000 +0100
+++ 24-quintela/build/arch/mips/sgi-ip22/ip22-setup.c 2003-03-26 17:53:58.000000000 +0100
@@ -142,8 +142,9 @@ void __init ip22_setup(void)
/* Now enable boardcaches, if any. */
indy_sc_init();
#endif
+#ifdef CONFIG_VT
conswitchp = NULL;
-
+#endif
/* Set the IO space to some sane value */
set_io_port_base (KSEG1ADDR (0x00080000));
diff -puN build/drivers/sgi/char/Makefile~newport build/drivers/sgi/char/Makefile
--- 24/build/drivers/sgi/char/Makefile~newport 2003-03-26 17:53:58.000000000 +0100
+++ 24-quintela/build/drivers/sgi/char/Makefile 2003-03-26 18:53:50.000000000 +0100
@@ -10,10 +10,11 @@
O_TARGET := sgichar.o
export-objs := newport.o rrm.o shmiq.o sgicons.o usema.o rrm.o
-obj-y := newport.o shmiq.o sgicons.o usema.o streamable.o
+obj-y := shmiq.o
obj-$(CONFIG_IP22_SERIAL) += sgiserial.o
+obj-$(CONFIG_SGI_NEWPORT_CONSOLE) += newport.o streamable.o
obj-$(CONFIG_SGI_DS1286) += ds1286.o
-obj-$(CONFIG_SGI_NEWPORT_GFX) += graphics.o rrm.o
+obj-$(CONFIG_SGI_NEWPORT_GFX) += sgicons.o graphics.o rrm.o usema.o
include $(TOPDIR)/Rules.make
diff -puN build/drivers/sgi/char/shmiq.c~newport build/drivers/sgi/char/shmiq.c
--- 24/build/drivers/sgi/char/shmiq.c~newport 2003-03-26 17:53:58.000000000 +0100
+++ 24-quintela/build/drivers/sgi/char/shmiq.c 2003-03-26 18:40:12.000000000 +0100
@@ -166,6 +166,7 @@ shmiq_forget_file (unsigned long fdes)
return 0;
}
+#ifdef CONFIG_SGI_NEWPORT_GFX
static int
shmiq_sioc (int device, int cmd, struct strioctl *s)
{
@@ -194,12 +195,12 @@ shmiq_sioc (int device, int cmd, struct
printk ("Unknown I_STR request for shmiq device: 0x%x\n", cmd);
return -EINVAL;
}
+#endif /* CONFIG_SGI_NEWPORT_GFX */
static int
shmiq_ioctl (struct inode *inode, struct file *f, unsigned int cmd, unsigned long arg)
{
struct file *file;
- struct strioctl sioc;
int v;
switch (cmd){
@@ -226,7 +227,10 @@ shmiq_ioctl (struct inode *inode, struct
v = shmiq_forget_file (arg);
return v;
- case I_STR:
+#ifdef CONFIG_SGI_NEWPORT_GFX
+ case I_STR: {
+ struct strioctl sioc;
+
v = get_sioc (&sioc, arg);
if (v)
return v;
@@ -234,6 +238,8 @@ shmiq_ioctl (struct inode *inode, struct
/* FIXME: This forces device = 0 */
return shmiq_sioc (0, sioc.ic_cmd, &sioc);
}
+#endif
+ }
return -EINVAL;
@@ -471,3 +477,4 @@ shmiq_init (void)
}
EXPORT_SYMBOL(shmiq_init);
+EXPORT_SYMBOL(shmiq_push_event);
diff -puN build/drivers/char/misc.c~newport build/drivers/char/misc.c
--- 24/build/drivers/char/misc.c~newport 2003-03-26 17:53:58.000000000 +0100
+++ 24-quintela/build/drivers/char/misc.c 2003-03-26 17:53:58.000000000 +0100
@@ -266,12 +266,7 @@ int __init misc_init(void)
pmu_device_init();
#endif
#ifdef CONFIG_SGI_NEWPORT_GFX
- gfx_register ();
-#endif
-#ifdef CONFIG_SGI_IP22
streamable_init ();
-#endif
-#ifdef CONFIG_SGI_NEWPORT_GFX
gfx_register ();
#endif
#ifdef CONFIG_TOSHIBA
_
--
In theory, practice and theory are the same, but in practice they
are different -- Larry McVoy
reply other threads:[~2003-03-27 2:53 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2u1dped2i.fsf@mandrakesoft.com \
--to=quintela@mandrakesoft.com \
--cc=linux-mips@linux-mips.org \
--cc=ralf@linux-mips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.