[flashrom] Porting flashrom to OpenBSD

Theo de Raadt deraadt at cvs.openbsd.org
Fri Jun 25 16:44:00 CEST 2010


> On 2010/06/25 08:32, Theo de Raadt wrote:
> > > > you're in CC of this mail because you sent the "unbreak pciutils" mail
> > > > to this list, and the failure mode is related.
> > > > http://marc.info/?l=openbsd-ports&m=126918139214769
> > > 
> > > Hmmm... So why is PCIOCWRITE failing, even when securelevel is 0 and 
> > > allowaperture=2...
> > > 
> > > I don't know this area at all well, but this looks worth investigating
> > > 
> > > /sys/dev/pci/pci.c
> > > 
> > >         case PCIOCWRITE:
> > >                 io = (struct pci_io *)data;
> > >                 switch (io->pi_width) {
> > >                 case 4:
> > >                         /* Make sure the register is properly aligned */
> > >                         if (io->pi_reg & 0x3)
> > >                                 return EINVAL;
> > >                         pci_conf_write(pc, tag, io->pi_reg, io->pi_data);
> > >                         error = 0;
> > >                         break;
> > >                 default:
> > >                         error = ENODEV;
> > >                         break;
> > >                 }
> > >                 break;
> > > 
> > > > Thanks, looks good. One small comment about installation in sbin,
> > > > though. flashrom can also work with programmers attached to serial ports
> > > > and USB, and those might work even for non-root users if appropriate
> > > > permissions are set (well, under most Unix-like OS, but OpenBSD might be
> > > > different). Due to that, some people think installing in bin instead of
> > > > sbin makes more sense.
> > > 
> > > I don't think the location is a problem..
> > > 
> > > > Stuart, does the pcilib abort happen on i386 and amd64?
> > > 
> > > I don't have an i386 box handy to try at the moment.
> > 
> > The aperture is for X.  Only one use at a time is permitted.
> 
> I should have mentioned, this was single-user.

The aperture is for X.




More information about the flashrom mailing list