The OpenNET Project / Index page

[ новости /+++ | форум | теги | ]

Интерактивная система просмотра системных руководств (man-ов)

 ТемаНаборКатегория 
 
 [Cписок руководств | Печать]

bus_release_resource (9)
  • >> bus_release_resource (9) ( FreeBSD man: Ядро )

  • BSD mandoc
     

    NAME

    
    
    bus_release_resource
    
     - release resources on a bus
    
     
    

    SYNOPSIS

       #include <sys/param.h>
       #include <sys/bus.h>

       #include <machine/bus.h>
       #include <sys/rman.h>
       #include <machine/resource.h>
    int bus_release_resource (device_t dev int type int rid struct resource *r);
     

    DESCRIPTION

    Free a resource allocated by bus_alloc_resource9. The resource must not be in use on release, i.e., call an appropriate function before (e.g. bus_teardown_intr9 for IRQs).

    Fa dev
    is the device that owns the resource.
    Fa type
    is the type of resource that is released. It must be of the same type you allocated it as before. See bus_alloc_resource9 for valid types.
    Fa rid
    is the resource ID of the resource. The Fa rid value must be the same as the one returned by bus_alloc_resource9.
    Fa r
    is the pointer to struct res i.e., the resource itself, returned by bus_alloc_resource9.

     

    RETURN VALUES

    Er EINVAL is returned, if the device Fa dev has no parent, 0 otherwise. The kernel will panic, if it cannot release the resource.  

    EXAMPLES

            /* deactivate IRQ */
            bus_teardown_intr(dev, foosoftc->irqres, foosoftc->irqid);
    
            /* release IRQ resource */
            bus_release_resource(dev, SYS_RES_IRQ, foosoftc->irqid,
                    foosoftc->irqres);
    
            /* release I/O port resource */
            bus_release_resource(dev, SYS_RES_IOPORT, foosoftc->portid,
                    foosoftc->portres);
    
     

    SEE ALSO

    bus_alloc_resource9, device(9), driver(9)  

    AUTHORS

    This manual page was written by An Alexander Langer Aq alex@big.endian.de .


     

    Index

    NAME
    SYNOPSIS
    DESCRIPTION
    RETURN VALUES
    EXAMPLES
    SEE ALSO
    AUTHORS


    Поиск по тексту MAN-ов: 




    Партнёры:
    PostgresPro
    Inferno Solutions
    Hosting by Hoster.ru
    Хостинг:

    Закладки на сайте
    Проследить за страницей
    Created 1996-2024 by Maxim Chirkov
    Добавить, Поддержать, Вебмастеру