Changeset 6843a9c in mainline for uspace/lib/c/include/device/pci.h


Ignore:
Timestamp:
2012-06-29T13:02:14Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
722912e
Parents:
ba72f2b (diff), 0bbd13e (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes

Trivial conflicts.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/include/device/pci.h

    rba72f2b r6843a9c  
    11/*
    2  * Copyright (c) 2009 Lukas Mejdrech
     2 * Copyright (c) 2011 Jiri Michalec
    33 * All rights reserved.
    44 *
     
    3030 * @{
    3131 */
    32 
    3332/** @file
    34  * Networking subsystem central module messages.
    35  * @see net_interface.h
    3633 */
    3734
    38 #ifndef LIBC_NET_NET_MESSAGES_H_
    39 #define LIBC_NET_NET_MESSAGES_H_
     35#ifndef LIBC_DEVICE_PCI_H_
     36#define LIBC_DEVICE_PCI_H_
    4037
    41 #include <ipc/net.h>
     38#include <async.h>
    4239
    43 /** Networking subsystem central module messages. */
     40#define PCI_DEVICE_ID  0x02
     41
    4442typedef enum {
    45         /** Return general configuration
    46          * @see net_get_conf_req()
    47          */
    48         NET_NET_GET_CONF = NET_FIRST,
    49         /** Return device specific configuration
    50          * @see net_get_device_conf_req()
    51          */
    52         NET_NET_GET_DEVICE_CONF,
    53         /** Return number of mastered devices */
    54         NET_NET_GET_DEVICES_COUNT,
    55         /** Return names and device IDs of all devices */
    56         NET_NET_GET_DEVICES,
    57         /** Notify the networking service about a ready device */
    58         NET_NET_DRIVER_READY
    59 } net_messages;
     43        IPC_M_CONFIG_SPACE_READ_8,
     44        IPC_M_CONFIG_SPACE_READ_16,
     45        IPC_M_CONFIG_SPACE_READ_32,
     46       
     47        IPC_M_CONFIG_SPACE_WRITE_8,
     48        IPC_M_CONFIG_SPACE_WRITE_16,
     49        IPC_M_CONFIG_SPACE_WRITE_32
     50} pci_dev_iface_funcs_t;
     51
     52extern int pci_config_space_read_8(async_sess_t *, uint32_t, uint8_t *);
     53extern int pci_config_space_read_16(async_sess_t *, uint32_t, uint16_t *);
     54extern int pci_config_space_read_32(async_sess_t *, uint32_t, uint32_t *);
     55
     56extern int pci_config_space_write_8(async_sess_t *, uint32_t, uint8_t);
     57extern int pci_config_space_write_16(async_sess_t *, uint32_t, uint16_t);
     58extern int pci_config_space_write_32(async_sess_t *, uint32_t, uint32_t);
    6059
    6160#endif
Note: See TracChangeset for help on using the changeset viewer.