Geoff Levand | 4 Nov 2005 22:27
Picon

pmac serial_pci_guess_board problem

Russell,

I found that the serial port probe code in drivers/serial/8250_pci.c 
no longer works properly for PowerMac G5 in 2.6.14.  It seems some new
code now takes the PCI device info directly from the G5's Open 
Firmware.  The trouble is that OF sets the address length to 16 bytes, 
not the expected 8 bytes.

Here's a fix, but I'd be interested to hear your comments.

-Geoff

Index: linux-2.6.14/drivers/serial/8250_pci.c
===================================================================
--- linux-2.6.14.orig/drivers/serial/8250_pci.c	2005-11-04 11:41:09.000000000 -0800
+++ linux-2.6.14/drivers/serial/8250_pci.c	2005-11-04 11:44:21.000000000 -0800
 <at>  <at>  -1478,7 +1478,11  <at>  <at> 
 	num_port = 0;
 	for (i = 0; i < PCI_NUM_BAR_RESOURCES; i++) {
 		if (pci_resource_flags(dev, i) & IORESOURCE_IO &&
+#if defined(CONFIG_PPC_PMAC64)
+		    pci_resource_len(dev, i) == 16 &&
+#else
 		    pci_resource_len(dev, i) == 8 &&
+#endif
 		    (first_port == -1 || (first_port + num_port) == i)) {
 			num_port++;
 			if (first_port == -1)

-------- Original Message --------
(Continue reading)

Benjamin Herrenschmidt | 4 Nov 2005 22:47

Re: pmac serial_pci_guess_board problem

On Fri, 2005-11-04 at 13:27 -0800, Geoff Levand wrote:
> Russell,
> 
> I found that the serial port probe code in drivers/serial/8250_pci.c 
> no longer works properly for PowerMac G5 in 2.6.14.  It seems some new
> code now takes the PCI device info directly from the G5's Open 
> Firmware.  The trouble is that OF sets the address length to 16 bytes, 
> not the expected 8 bytes.
> 
> Here's a fix, but I'd be interested to hear your comments.

I wouldn't do the ifdef at all ... Why do we bother testing the size
anyway ? Russell ?

Ben.

-
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Russell King | 4 Nov 2005 23:50
Picon

Re: pmac serial_pci_guess_board problem

On Sat, Nov 05, 2005 at 08:47:40AM +1100, Benjamin Herrenschmidt wrote:
> On Fri, 2005-11-04 at 13:27 -0800, Geoff Levand wrote:
> > Russell,
> > 
> > I found that the serial port probe code in drivers/serial/8250_pci.c 
> > no longer works properly for PowerMac G5 in 2.6.14.  It seems some new
> > code now takes the PCI device info directly from the G5's Open 
> > Firmware.  The trouble is that OF sets the address length to 16 bytes, 
> > not the expected 8 bytes.
> > 
> > Here's a fix, but I'd be interested to hear your comments.
> 
> I wouldn't do the ifdef at all ... Why do we bother testing the size
> anyway ? Russell ?

That's the expected size of the ports.  Remember this is a heuristic
for finding the correct details of the ports.  Some cards seem to
have regions of 16 bytes which aren't serial ports.

I'm _very_ nervous about changing this, especially as it pre-dates
my time and you seem to imply that it's an OF problem.  Can't it be
fixed up in a PCI quirk?

--

-- 
Russell King
 Linux kernel    2.6 ARM Linux   - http://www.arm.linux.org.uk/
 maintainer of:  2.6 Serial core
-
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo <at> vger.kernel.org
(Continue reading)

Benjamin Herrenschmidt | 4 Nov 2005 23:53

Re: pmac serial_pci_guess_board problem


> That's the expected size of the ports.  Remember this is a heuristic
> for finding the correct details of the ports.  Some cards seem to
> have regions of 16 bytes which aren't serial ports.
> 
> I'm _very_ nervous about changing this, especially as it pre-dates
> my time and you seem to imply that it's an OF problem.  Can't it be
> fixed up in a PCI quirk?

Could be yes. a ppc64 specific one that re-do the BAR sizing... I wonder
what's up with OF tho ...  Maybe Apple's OF can't assign BARs smaller
than 16 bytes ?

Ben.

-
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Arnd Bergmann | 5 Nov 2005 17:26
Picon
Gravatar

[PATCH 00/25] reduce code in fs/compat_ioctl.c

On Sünnavend 05 November 2005 00:51, Christoph Hellwig wrote:
> On Sat, Nov 05, 2005 at 12:10:46AM +0100, Arnd Bergmann wrote:
> >
> > BTW, I now have a set of 25 patches that moves all handlers from
> > fs/compat_ioctl.c over to the respective drivers and subsystems,
> > but I'm not sure how to best test that.
> > I intend to at least give it a test run on my Opteron for the whatever
> > ioctls I normally use, but the rest is just guesswork. Christoph,
> > can you review those patches?
> 
> I'm not sure moving everything from fs/compat_ioctl.c is a good idea.
> Everything that is just in a single driver or subsystem that has
> common ioctl code - sure.  else it doesn't make a lot of sense.

Ok, here is my full set of patches, let's see which ones are
sensible and which ones we are better off without.

Getting rid of fs/compat_ioctl.c completely could at least simplify
the compat_sys_ioctl() code a bit and would also make sure that
we only build the handlers into the kernel that can be used
potentially, which reduces the binary size.

The patch set is still largely untested, except for a single
compile test, but at least some of the patches are very simple,
so maybe I can get a quick ack or nack on them.

In general, I'm just moving over the handlers to the respective
subsystem without changing the logic, so the patch should not
have any effect on the ioctl operation itself, but it also
means that the handlers still use compat_alloc_user_space
(Continue reading)

Arnd Bergmann | 5 Nov 2005 17:27
Picon
Gravatar

[PATCH 22/25] serial: move ioctl32 code to tty_io.c

All driver implementing TIOCGSERIAL are tty drivers, so
the conversion handler can be part of tty_compat_ioctl.

In a perfect world, this would live in serial_core.c, but
there are still a number of drivers that are not moved
over to use that yet. If it were in serial_core, it
could also live without the get_fs/set_fs hacks.

CC: rmk+serial <at> arm.linux.org.uk
CC: linux-serial <at> vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd <at> arndb.de>

Index: linux-cg/drivers/char/tty_io.c
===================================================================
--- linux-cg.orig/drivers/char/tty_io.c	2005-11-05 14:22:34.000000000 +0100
+++ linux-cg/drivers/char/tty_io.c	2005-11-05 15:42:22.000000000 +0100
 <at>  <at>  -104,7 +104,6  <at>  <at> 
 #include <linux/vt_kern.h>
 #include <linux/selection.h>
 #include <linux/devfs_fs_kernel.h>
-
 #include <linux/kmod.h>

 #undef TTY_DEBUG_HANGUP
 <at>  <at>  -153,7 +152,7  <at>  <at> 
 static int tty_release(struct inode *, struct file *);
 int tty_ioctl(struct inode * inode, struct file * file,
 	      unsigned int cmd, unsigned long arg);
-long tty_compat_ioctl(struct file * file, unsigned int cmd, unsigned long arg);
+static long tty_compat_ioctl(struct file * file, unsigned int cmd, unsigned long arg);
(Continue reading)

Ali Usman | 7 Nov 2005 12:28
Picon
Favicon

ASSISTANCE

ARTS & CRAFT COMPANY PLC.
DL0311 VAUXHALL CROSS LONDON
UNITED KINGDOM.
E-MAIL:aliusman4 <at> yahoo.com

Attn:Sir/Ma,

With due respect to you, I am sorry for any inconveniences or embarrassement 
this my letter of assistance may cause you. I am writing following an 
impressive information we got about you through a consultancy firm under 
UK/USA/CA. CHAMBER OF COMMERCE AND INDUSTRY. Thus we assured your capability 
and reliability to champion a business of great magnitude.

I am Mr.Ali Usman, the managing director of the above mentioned company. 
Base on the assurance given on your behalf, my company has appoint you as 
our debt collector from our overseas creditors. The creditors always send us 
CHEQUES for our payment, but foreign cheque take LONGER time to clear and 
sometimes some of them got lost on transit, which impact a great lost to 
this Company. It is on this effect, we the management outstand a dept 
collect or overseas. You haven been selected on these contract, the 
management has agreed that any debt YOU collected on our behalf, 5% is 
allowed for you as your share while the remaining will be remitted to us 
through wire transfer on our coparate  account.

To commence on this transaction, you are to send the following in your 
reply:
1. Name you want the cheque to be raised.
2. Direct telephone and fax numbers
3. Mailing address
4. Your company name if any.
(Continue reading)

Bjorn Helgaas | 7 Nov 2005 22:59
Picon
Favicon

[PATCH] serial: remove 8250_acpi (subsumed by 8250_pnp and PNPACPI)

With the combination of PNPACPI and 8250_pnp, we no longer need
8250_acpi.

The only in-tree configs that contain CONFIG_SERIAL_8250_ACPI are ia64.
ia64 users should make sure CONFIG_PNP and CONFIG_PNPACPI are set so
8250_pnp.c can discover built-in serial ports.  Tony has already
accepted a patch to turn them on in the default configs.

Note: This depends on these patches that are in 2.6.14-mm1, but are
not in Linus' tree yet:
    pnpacpi-handle-address-descriptors-in-_prs.patch
    pnpacpi-handle-address-descriptors-in-_prs-fix-for-git-acpi-change.patch

Signed-off-by: Bjorn Helgaas <bjorn.helgaas <at> hp.com>

Index: work-mm1/drivers/serial/Kconfig
===================================================================
--- work-mm1.orig/drivers/serial/Kconfig	2005-11-03 10:39:15.000000000 -0700
+++ work-mm1/drivers/serial/Kconfig	2005-11-03 13:26:31.000000000 -0700
 <at>  <at>  -77,14 +77,6  <at>  <at> 

 	  If unsure, say N.

-config SERIAL_8250_ACPI
-	bool "8250/16550 device discovery via ACPI namespace"
-	default y if IA64
-	depends on ACPI && SERIAL_8250
-	---help---
-	  If you wish to enable serial port discovery via the ACPI
-	  namespace, say Y here.  If unsure, say N.
(Continue reading)

Ronda | 10 Nov 2005 02:51

Urgently people for work about the Internet the company are required.

Thank You for Your interest.work  

Job for you! stats  

MakePay Corporation offers the External Financial Management Services leadership, 
experience and results in cash flow management.  you  
We offer You the job of finance manager. inside
Thank You for Your interest.the
Contact us on our post client and specify the.  site
Full name
Address
Contact info (e-mail, phone, fax)
And we shall contact you within one day

Details on a site www.makepay.biz

Contact as support <at> makepay.biz

-
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo <at> vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Gmane