lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 15 Sep 2007 12:14:09 +1000
From:	Rusty Russell <rusty@...tcorp.com.au>
To:	Andi Kleen <ak@....de>
Cc:	lguest <lguest@...abs.org>,
	lkml - Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH] Introduce "used_vectors" bitmap which can be used to
	reserve vectors.

On Fri, 2007-09-14 at 09:44 +0200, Andi Kleen wrote:
> On Fri, Sep 14, 2007 at 03:14:09PM +1000, Rusty Russell wrote:
> > This simplifies the io_apic.c __assign_irq_vector() logic and removes
> > the explicit SYSCALL_VECTOR check, and also allows for vectors to be
> > reserved by other mechanisms (ie. lguest).
> 
> Seems reasonable even as a cleanup.
> 
> >  
> >  int panic_on_unrecovered_nmi;
> > +
> > +DECLARE_BITMAP(used_vectors, NR_VECTORS);
> > +EXPORT_SYMBOL_GPL(used_vectors);
> 
> But what is the export good for? Since it's only used at boot
> a module cannot do anything useful with it.

Hmm, maybe I misunderstood.  I assumed that create_irq() was also called
later to get irqs for any devices which appeared later.  Although I can
at least check it's not in use.

The current lguest patch uses it like so (syscall_vector is a module
parameter):

int init_interrupts(void)
{
	/* If they want some strange system call vector, reserve it now */
	if (syscall_vector != SYSCALL_VECTOR
	    && test_and_set_bit(syscall_vector, used_vectors)) {
		printk("lg: couldn't reserve syscall %u\n", syscall_vector);
		return -EBUSY;
	}
	return 0;
}

Thanks,
Rusty.


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ