CN107729071B - A kind of method and device initializing network interface card - Google Patents

A kind of method and device initializing network interface card Download PDF

Info

Publication number
CN107729071B
CN107729071B CN201610648308.6A CN201610648308A CN107729071B CN 107729071 B CN107729071 B CN 107729071B CN 201610648308 A CN201610648308 A CN 201610648308A CN 107729071 B CN107729071 B CN 107729071B
Authority
CN
China
Prior art keywords
cpu
network interface
interface card
host
storage region
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610648308.6A
Other languages
Chinese (zh)
Other versions
CN107729071A (en
Inventor
蔡世顺
韩天
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201610648308.6A priority Critical patent/CN107729071B/en
Publication of CN107729071A publication Critical patent/CN107729071A/en
Application granted granted Critical
Publication of CN107729071B publication Critical patent/CN107729071B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading

Abstract

The embodiment of the invention discloses a kind of method and devices for initializing network interface card, are related to electronic technology field, can solve network interface card and are merely able to adapt to a kind of host execution PXE starting of cpu type, can not cross-platform the problem of using PXE function.The specific scheme is that being stored with the driver of initialization network interface card corresponding with one kind CPU in each storage region at least two storage regions, the driver stored in each storage region corresponds to different types of CPU;The determining cpu type with the CPU of the host of network card binding;From at least two storage regions, determine the storage region for being stored with driver corresponding with the cpu type of the CPU of host, and the Address space mappinD of determining storage region initializes network interface card so that host loads the driver in corresponding address space to host.During the embodiment of the present invention is applied to network interface card initialization.

Description

A kind of method and device initializing network interface card
Technical field
The present invention relates to electronic technology field more particularly to a kind of method and devices for initializing network interface card.
Background technique
Pre-boot Execution Environment (English: Preboot Execution Environment, referred to as: PXE) it is the one of network interface card Item critical function.For example, being exactly to pass through net by network installation operating system (English: Operating System, abbreviation: OS) What the PXE of card was realized.
Wherein, it is integrated with an on-demand memory (English: option rom) on usual network interface card, is deposited in the option rom Contain the driver of the network interface card.Host can pass through basic input output system (English: Basic Input Output System, referred to as: BIOS) or unified Extensible Firmware Interface (English: Unified Extensible Firmware Interface, referred to as: UEFI) driver that the network interface card is loaded when executing PXE, pass through the initialization of PXE realization network interface card.
Wherein, it is stored in the option rom of existing network interface card (including: Intel, broadcom and mellanox etc.) Driver generally all only can type be in central processing unit (English: Central Processing Unit, referred to as: CPU) It is run on the host of x86, and the host that cpu type is ARM64 cannot be run on.In order to be applied to cpu type by network interface card The host of ARM64, network interface card producer are that network interface card individually develops the option rom for having compiled adaptation ARM64 host.
But the problem is that: after developing the option rom of compiling adaptation ARM64 host for network interface card, though the network interface card The host that cpu type is ARM64 can be so run on, cannot but be run on the host that cpu type is x86.That is the prior art In network interface card be only capable of adapting to the host of cpu type a kind of and execute PXE starting, cannot be used on the host of different cpu types PXE function.
Summary of the invention
The embodiment of the present invention provides a kind of method and device for initializing network interface card, and can solve network interface card can only adapt to one The host of kind cpu type executes PXE starting, cannot be the problem of using PXE function on the host of different cpu types.
In order to achieve the above objectives, the embodiment of the present invention adopts the following technical scheme that
In a first aspect, providing a kind of method for initializing network interface card, it is applied to network interface card, each of at least two storage regions The driver of initialization network interface card corresponding with one kind CPU, the driving stored in each storage region are stored in storage region Program corresponds to different types of CPU, and the method for the initialization network interface card comprises determining that the CPU with the CPU of the host of network card binding Type;From at least two storage regions, the storage for being stored with driver corresponding with the cpu type of the CPU of host is determined Region, and by the Address space mappinD of determining storage region to host, so that host loads the drive in corresponding address space Dynamic program initializes network interface card.
By this programme, can be stored in each storage region at least two storage regions and CPU pairs of one kind The driver for the initialization network interface card answered, and the driver stored in each storage region corresponds to different types of CPU, In this way, network interface card can adapt to the host of different types of CPU.For example, network interface card can be in the CPU class for the CPU for determining host After type, then by the Address space mappinD of storage region corresponding with the cpu type of the CPU of the host to host.In this way, host is then The driver in the address space for adapting to the cpu type of CPU of the host can be loaded.It can be seen that in this programme The host that network interface card can adapt to different types of CPU executes PXE starting, i.e., network interface card can be on the host of different cpu types Using PXE function, the host of different cpu types is initialized using PXE function to the network interface card.
In one possible implementation, network interface card can by way of the register read reserved field from network interface card, Determine the cpu type of the CPU of host.Specifically, above-mentioned " the determining cpu type with the CPU of the host of network card binding " can wrap Include: from the register read reserved field of network interface card, which is used to indicate the cpu type of the CPU of host;According to reading Reserved field determines the cpu type of the CPU of host.Wherein, at least one byte in above-mentioned reserved field or at least one Bit is used to indicate the cpu type of the CPU of host, and the cpu type of the CPU of the host is that reserved field is written in host.For example, Host can be after powering on and establishing connection with network interface card, will be reserved in the register of the cpu type write-in network interface card of the CPU of host Field.Illustratively, the register of above-mentioned network interface card can quickly interconnect (English: Peripheral for the peripheral assembly of network interface card Component Interconnect Express, referred to as: PCIE) configuration space registers.By this programme, network interface card can be from The register read reserved field of network interface card, come determine host CPU cpu type, so as to according to the CPU of the CPU of host Type determines the Address space mappinD of corresponding storage region to host.
In one possible implementation, it is contemplated that current many hosts are not supported " by space register Reserved field configuration host CPU cpu type " mode indicated to network interface card the host CPU cpu type;The present invention In embodiment, it can be opened in such a way that status switch (such as wire jumper) is set on network interface card by network interface card or Host Detection state The current state of pass determines the cpu type of the CPU of host.Specifically, the CPU of the CPU of the host of above-mentioned determination and network card binding The method that type network interface card determines the cpu type of the CPU of host may include: the current state of detecting state switch, and according to shape Corresponding relationship between the cpu type of the CPU of the state and host of the current state and status switch of state switch, determines master The cpu type of the CPU of machine.It is envisioned that the different conditions for the status switch being arranged on network interface card can serve to indicate that difference Cpu type can then indicate that the CPU of host is the first kind for example, when status switch (first state) in the open state CPU can then indicate that the CPU of host is the second class CPU when status switch is in close state (the second state).Wherein, it grasps Making personnel can be when installing network interface card for host, and according to the cpu type of the CPU of host, the status switch being arranged on network interface card is in Corresponding state.In this way, the current state that network interface card or host can be switched by detecting state, determines the CPU of the CPU of host Type.
By this implementation, even host is not supported " to configure the CPU of host by the reserved field in register Cpu type " mode indicated to network interface card the host CPU cpu type, can also be by the way that status switch be arranged on network interface card Mode, the current state switched by network interface card detecting state determines the cpu type of the CPU of host.
In one possible implementation, at least two storage regions are at least two storage cores being integrated on network interface card Piece;Alternatively, at least two sections of memory spaces, storage chip that at least two storage regions are same storage chip are integrated in the net On card.
In one possible implementation, above-mentioned at least two storage region may include in network interface card and/or host, I.e. network interface card and/or host have at least two storage regions.
Second aspect provides a kind of method for initializing network interface card, is applied to host, each of at least two storage regions The driver of initialization network interface card corresponding with one kind CPU, the driving stored in each storage region are stored in storage region Program corresponds to different types of CPU;The method of the initialization network interface card includes: reserved field of the host in the register of network interface card The cpu type of the CPU of host is written, so that network interface card reflects the address space of the corresponding storage region of the cpu type of the CPU of host It penetrates to host;Host reads and loads the address that network interface card is mapped to host.
By this programme, can be stored in each storage region at least two storage regions and CPU pairs of one kind The driver for the initialization network interface card answered, and the driver stored in each storage region corresponds to different types of CPU, In this way, network interface card can adapt to the host of different types of CPU.Wherein, host can write down characters in the pre- of the register of network interface card The cpu type of the CPU of section write-in host makes the cpu type of the CPU of reserved field instruction host, so that network interface card can be by host CPU the corresponding storage region of cpu type Address space mappinD give the host.In this way, the host can then load adaptation Driver in the address space of the cpu type of the CPU of the host, the host can then initialize the network interface card. It can be seen that the host that the network interface card in this programme can adapt to different types of CPU executes PXE starting, i.e. network interface card can be PXE function is used on the host of different cpu types, and the host of different cpu types is allowed to use PXE function to the network interface card It is initialized.
The third aspect provides a kind of network interface card, which includes: data-interface and processor.Data-interface is used for and master Machine data interaction.Processor, the cpu type of the CPU for determining the host connecting with data-interface;From at least two memory blocks It in domain, determines and is stored with the storage region of driver corresponding with the cpu type of the CPU of host, and by determining memory block The Address space mappinD in domain is to host, so that host loads the driver in corresponding address space, carries out to network interface card initial Change.Wherein, initialization network interface card corresponding with one kind CPU is stored in each storage region in above-mentioned at least two storage region Driver, the driver stored in each storage region corresponds to different types of CPU.
In one possible implementation, status switch is provided on above-mentioned network interface card.Processor is specifically used for detection shape The current state of state switch, and according to the CPU of the current state of status switch and the state of status switch and the CPU of host Corresponding relationship between type determines the cpu type of the CPU of host.
In one possible implementation, above-mentioned processor, specifically for the register read reserved field from network interface card, Reserved field is used to indicate the cpu type of the CPU of host;The cpu type of the CPU of host is determined according to the reserved field of reading.
In one possible implementation, above-mentioned network interface card can also include: memory, the memory include it is above-mentioned at least Two storage regions are stored in the on-demand memory of each of at least two storage region corresponding with one kind CPU initial Change the driver of network interface card, the driver stored in each on-demand memory corresponds to different types of CPU.
In one possible implementation, at least two storage regions are at least two storage cores being integrated on network interface card Piece;Alternatively, at least two sections of memory spaces, storage chip that at least two storage regions are same storage chip are integrated in network interface card On.
Fourth aspect provides a kind of network interface card, is stored in each storage region at least two storage regions and one kind The driver of the corresponding initialization network interface card of central processor CPU, the driver stored in each storage region are corresponding In different types of CPU.The network interface card comprises determining that module and mapping block.Determining module, for the determining master with network card binding The cpu type of the CPU of machine;From at least two storage regions, determination is stored with corresponding with the cpu type of the CPU of the host Driver storage region.Mapping block, the Address space mappinD of the storage region for determining determining module is to master Machine initializes network interface card so that host loads the driver in corresponding address space.
In one possible implementation, stateful switch can be set on above-mentioned network interface card.Above-mentioned determining module, specifically For: the current state of detecting state switch, and according to the current state of status switch and the state of status switch and host CPU cpu type between corresponding relationship, determine the cpu type of the CPU of host.
In one possible implementation, above-mentioned determining module, is specifically used for: writeeing down characters in advance from the register read of network interface card Section, reserved field are used to indicate the cpu type of the CPU of host;The CPU class of the CPU of host is determined according to the reserved field of reading Type.
In one possible implementation, above-mentioned network interface card can also include memory module, which includes at least Two storage regions.Alternatively, host has at least two storage regions.
In one possible implementation, at least two storage regions are at least two storage cores being integrated on network interface card Piece;Alternatively, at least two sections of memory spaces, storage chip that at least two storage regions are same storage chip are integrated in the net On card.
It should be noted that each functional module in fourth aspect and its various optional ways is to execute above-mentioned On the one hand the method for and described in the various optional ways of first aspect initializing network interface card, and to network interface card carry out in logic It divides.Each functional module in fourth aspect and its various optional ways, as determining module and mapping block also can integrate It is realized in a processing module (being equivalent to processor described in the third aspect).The third aspect and in the embodiment of the present invention The specific descriptions and its technical effect of each functional module of network interface card in four aspects can be found in above-mentioned first aspect and its various Associated description in optional way, details are not described herein again.
5th aspect, provides a kind of computer readable storage medium, is stored with computer in computer readable storage medium It executes instruction, when the processor in network interface card executes the computer executed instructions, network interface card executes above-mentioned first aspect or first The method of network interface card is initialized shown in the various possible implementations of aspect.
6th aspect, provides a kind of host, which includes: network interface card connector and processor.Network interface card connector, for tying up Determine network interface card, the network interface card includes at least two storage regions, is deposited in each storage region at least two storage region The driver of initialization network interface card corresponding with one kind CPU is contained, the driver stored in each storage region corresponds to not The CPU of same type.Processor carries out data interaction by network interface card connector and network interface card, in the network interface card that network interface card connector is bound The cpu type of the CPU of the reserved field write-in host of register, so that network interface card is by the corresponding storage of the cpu type of the CPU of host The Address space mappinD in region is to host;The driver in the address space of network interface card mapping is read and loaded, network interface card is carried out Initialization.
7th aspect, provides a kind of host, which includes: link block, writing module and initialization module.Connect mould Block, for binding network interface card, the network interface card includes at least two storage regions, each storage at least two storage region The driver of initialization network interface card corresponding with one kind CPU, the driver stored in each storage region are stored in region Corresponding to different types of CPU.Master is written in the reserved field of writing module, the register of the network interface card for binding in link block The cpu type of the CPU of machine, so that network interface card gives the Address space mappinD of the corresponding storage region of the cpu type of the CPU of host to master Machine.Initialization module, the driver in address space for reading and loading network interface card mapping, initializes network interface card.
It should be noted that each functional module in the 7th aspect and its various optional ways is to execute above-mentioned the The method that network interface card is initialized described in the various optional ways of two aspects and second aspect, and to host carry out in logic It divides.Each functional module in 7th aspect and its various optional ways, as communication module and writing module also can integrate It is realized in a processing module (being equivalent to processor described in the 6th aspect).6th aspect and the in the embodiment of the present invention The specific descriptions and its technical effect of each functional module of host in seven aspects can be found in above-mentioned second aspect and its various Associated description in optional way, details are not described herein again.
Eighth aspect provides a kind of computer readable storage medium, is stored with computer in computer readable storage medium It executes instruction, when the processor in host executes the computer executed instructions, host executes above-mentioned second aspect or second The method of network interface card is initialized shown in the various possible implementations of aspect.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of invention without any creative labor, may be used also for those of ordinary skill in the art To obtain other drawings based on these drawings.
Fig. 1 is a kind of PXE networking schematic diagram provided in an embodiment of the present invention;
Fig. 2 is a kind of method flow diagram for initializing network interface card provided in an embodiment of the present invention;
Fig. 3 is the method flow diagram of another initialization network interface card provided in an embodiment of the present invention;
Fig. 4 is the method flow diagram of another initialization network interface card provided in an embodiment of the present invention;
Fig. 5 is a kind of composed structure schematic diagram of network interface card provided in an embodiment of the present invention;
Fig. 6 is the composed structure schematic diagram of another network interface card provided in an embodiment of the present invention;
Fig. 7 is the composed structure schematic diagram of another network interface card provided in an embodiment of the present invention;
Fig. 8 is a kind of composed structure schematic diagram of host provided in an embodiment of the present invention;
Fig. 9 is the composed structure schematic diagram of another host provided in an embodiment of the present invention;
Figure 10 is the composed structure schematic diagram of another host provided in an embodiment of the present invention.
Specific embodiment
In the description of the present invention, unless otherwise indicated, " at least two " or the meaning of " plurality " is refer to two or two More than.For example, at least two on-demand memories refer to two or more on-demand memories, multiple processors refer to two or More than two processors.
In addition, the term " includes " being previously mentioned in description of the invention and " having " and their any deformation, it is intended that It is to cover and non-exclusive includes.Such as the process, method, system, product or equipment for containing a series of steps or units do not have It is defined in listed step or unit, but optionally further comprising the step of other are not listed or unit, or optionally It further include the other step or units intrinsic for these process, methods, product or equipment.
In being described below, for illustration and not for limitation, propose such as specific system structure, interface, technology it The detail of class understands the present invention to cut thoroughly.However, it will be clear to one skilled in the art that there is no these specific The present invention also may be implemented in the other embodiments of details.In other situations, omit to well-known device, circuit and The detailed description of method, in case unnecessary details interferes description of the invention.
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention is retouched in detail It states, it is clear that described embodiment is only a part of the embodiments of the present invention, rather than whole embodiments.
The method and device of initialization network interface card provided in an embodiment of the present invention can be applied to the process that host executes PXE In, specifically, the initialization of network interface card can be realized during executing PXE by being equipped with the host of network interface card.
Referring to FIG. 1, it illustrates a kind of PXE networking schematic diagrams provided in an embodiment of the present invention.As shown in Figure 1, at least One PXE client (host of network interface card is equipped in the application), which can be interacted by network with PXE server, executes PXE.
Wherein, host needs to load network interface card and is mapped to host during interacting execution PXE with PXE server Driver in the address space of option rom initializes the network interface card.But the problem is that: it is existing Network interface card can only adapt to a kind of host of cpu type, cross-platform can not use.
Host in the embodiment of the present invention can for personal computer (English: Personal Computer, referred to as: PC), Smart phone, tablet computer etc. are equipped with network interface card and access the computer equipment or terminal of network by network interface card.
A kind of method and device initializing network interface card provided in an embodiment of the present invention may include in network interface card and/or host At least two storage regions, be stored in each storage region at least two storage region it is corresponding with one kind CPU just The driver of beginningization network interface card, the driver stored in each storage region correspond to different types of CPU.In this way, network interface card The storage for being stored with driver corresponding with the cpu type of the CPU of host can be determined from least two storage regions Region, and by the Address space mappinD of determining storage region to host, so that host loads the drive in corresponding address space Dynamic program initializes network interface card.I.e. the network interface card can adapt to the host of different types of CPU, i.e. the network interface card can be across Platform uses.
For example, integrated on network interface card there are two for storage region (the first storage region and the second storage region), this It can store the driver of the corresponding initialization network interface card of first kind CPU in one storage region, stored in the second storage region There is the driver of the corresponding initialization network interface card of the second class CPU.Wherein, first kind CPU and the second class CPU is different classes of CPU.For example, first kind CPU can be the CPU that cpu type is x86, the second class CPU can be the CPU that cpu type is ARM64; Alternatively, first kind CPU can be the CPU that cpu type is ARM64, the second class CPU can be the CPU that cpu type is x86, this hair Bright embodiment is without limitation.Certainly, first kind CPU and the second class CPU can also be other kinds of CPU, not limit to In x86 or ARM64.
It is envisioned that not only can integrate two option rom, the network interface card on network interface card in the embodiment of the present invention On can also integrate three or three or more for storing the driver of the corresponding initialization network interface card of different types of CPU option rom.In this way, the network interface card can be suitable for the host of a variety of different types of CPU.
It should be noted that in embodiments of the present invention, above-mentioned at least two storage region can integrate on network interface card, or Person may include in host.
With reference to the accompanying drawing, by specific embodiment and its application scenarios to provided in an embodiment of the present invention a kind of initial The method and device for changing network interface card is described in detail.
The embodiment of the present invention provides a kind of method for initializing network interface card, in embodiments of the present invention, at least two memory blocks The driver of initialization network interface card corresponding with one kind CPU is stored in each storage region in domain, in each storage region The driver of storage corresponds to different types of CPU.Specifically, as shown in Fig. 2, the method for the initialization network interface card includes:
The determining cpu type with the CPU of the host of network card binding of S201, network interface card.
Wherein, network interface card can be from the register read reserved field of network interface card, to determine the CPU of the host of installing the network interface card The current state for the status switch that cpu type or the network interface card can be arranged on the network interface card by detection, to determine host The cpu type of CPU.
From at least two storage regions, determination is stored with drive corresponding with the cpu type of the CPU of host for S202, network interface card The storage region of dynamic program.
As an example it is assumed that at the beginning of being stored with first kind CPU in the first storage region in above-mentioned at least two storage region The driver of beginningization network interface card is stored with the driver of the second class CPU initialization network interface card in the second storage region;Therefore, if Network interface card determines that the cpu type of the CPU of host is first kind CPU, then can determine and be stored with driving corresponding with first kind CPU The storage region of program is the first storage region, then by the Address space mappinD of the first storage region to host.
In an implementation of the embodiment of the present invention, above-mentioned at least two storage region can integrate on network interface card. In this implementation, network interface card can be stored at least two storage regions integrated in network interface card with the CPU's of host The Address space mappinD of the storage region of the corresponding driver of cpu type is to host.
In another implementation of the embodiment of the present invention, above-mentioned at least two storage region be may include in host In.In this implementation, network interface card it is determining with after the cpu type of the CPU of the host of network card binding, then can will be in host In at least two storage regions for including, it is stored with the storage region of driver corresponding with the cpu type of the CPU of host Address space mappinD is to host.
It should be noted that above-mentioned S201 and S202 can also be executed by host, i.e. host determination and network card binding The cpu type of the CPU of host, from least two storage regions, determination is stored with corresponding with the cpu type of the CPU of host The storage region of driver, and by the Address space mappinD of determining storage region to host.Specifically, can be by host For carrying out the functional module or control chip of network interface card initialization in CPU or host.
S203, network interface card are by the Address space mappinD of determining storage region to host.
The driver in address space that S204, host load network interface card map, initializes network interface card.
The Address space mappinD of the cpu type (such as first kind CPU) of the CPU of the host will be adapted to host in network interface card Afterwards, host can then read and load the driver in the address space, initialize to the network interface card.
It is envisioned that host can after it power on and detect network interface card is installed on the host, by BIOS or UEFI loads the driver in the address space of network interface card mapping when executing PXE, and the initialization of network interface card is realized by PXE. Specifically, host method that network interface card is initialized can with reference to associated description in the prior art, the embodiment of the present invention this In repeat no more.
The method of initialization network interface card provided in an embodiment of the present invention, can be in each storage at least two storage regions The driver of initialization network interface card corresponding with one kind CPU, and the driving stored in each storage region are stored in region Program corresponds to different types of CPU, in this way, network interface card can adapt to the host of different types of CPU.Wherein, network interface card can With empty after the cpu type for the CPU for determining host, then by the address of storage region corresponding with the cpu type of the CPU of the host Between be mapped to host.In this way, host can then load the driving in the address space for adapting to the cpu type of CPU of the host Program.It can be seen that the host that the network interface card in this programme can adapt to different types of CPU executes PXE starting, i.e., network interface card can To use PXE function on the host of different cpu types, the host of different cpu types is allowed to use PXE function to this Network interface card is initialized.
Optionally, in the first application scenarios of the embodiment of the present invention, network interface card can pass through the register (example from network interface card Such as PCIE configuration space registers) read reserved field mode, determine the cpu type of the CPU of host.Wherein, above-mentioned reserved At least one byte in field is used to indicate the cpu type of the CPU of host.
In the present embodiment, before register read reserved field of the network interface card from network interface card, host needs the deposit in network interface card The cpu type of the CPU of the host is written in the reserved field of device.Specifically, in conjunction with Fig. 2, as shown in figure 3, before S201, this hair The method of bright embodiment can also include S201 ':
The cpu type of the CPU of the host, the reserved field are written in the reserved field of the register of network interface card for S201 ', host It is used to indicate the cpu type of the CPU of host.
Wherein, the cpu type that above-mentioned reserved field is used to indicate the CPU of host is specifically as follows: in reserved field extremely A few byte or at least one bit are used to indicate the cpu type of the CPU of host.
Illustratively, reserved field of the embodiment of the present invention here with host in the PCIE configuration space registers of network interface card is write The cpu type for entering the CPU of the host, for the cpu type for the CPU for making in reserved field byte be used to indicate host, Assuming that being stored with the driving journey of first kind CPU initialization network interface card in the first storage region in above-mentioned at least two storage region Sequence is stored with the driver of the second class CPU initialization network interface card in the second storage region.If the said one word in reserved field Section is " 1 ", then it represents that the CPU of the host is first kind CPU;If the said one byte in reserved field is " 0 ", then it represents that should The CPU of host is the second class CPU.Assuming that the CPU of host is first kind CPU;So the host can then match the PCIE of network interface card The said one byte emptied in the reserved field of inter-register is set as 1.
Certainly, in the embodiment of the present invention, host can also use two or three in reserved field, or even more Byte indicates the cpu type of the CPU of the host, and the embodiment of the present invention is without limitation.Host uses in reserved field extremely Few two bytes indicate the mode of the cpu type of the CPU of the host and the CPU of the above-mentioned CPU using a byte instruction host The mode of type is similar, and the embodiment of the present invention is here with no restrictions.
It should be noted that in embodiments of the present invention, the register of network interface card includes but is not limited to the PCIE of above-mentioned network interface card The register of configuration space registers, network interface card can also be other registers in addition to PCIE configuration space registers, this hair Bright embodiment is not described in detail here.
It is envisioned that host can powered on and detected on the host after installation network interface card, it can be in starting BIOS Or UEFI, when initializing PCIE device, the PCIE of the instruction information write-in network interface card of the cpu type of the CPU of the host is configured The reserved field of space register.
Specifically, as shown in figure 3, the S201 in Fig. 2 may include S201a-S201b:
From the register read reserved field of network interface card, which is used to indicate the CPU of the CPU of host for S201a, network interface card Type.
S201b, network interface card determine the cpu type of the CPU of host according to the reserved field of reading.
Wherein, at least one byte in reserved field indicates that the CPU of the host is first kind CPU or the second class CPU.
By this programme, network interface card can be by reading the reserved field of the register of network interface card, to determine the CPU of host automatically Cpu type, so as to determined according to the cpu type of the CPU of host the Address space mappinD of corresponding on-demand memory to Host.
It should be noted that above-mentioned S201 ', S201a and S201b can also be executed by host, i.e., host can from The cpu type of the CPU of the host is written in the reserved field of the register of network interface card, then writes down characters in advance from the register read of network interface card Section, and determine according to the reserved field of reading the cpu type of the CPU of host.Specifically, can be by the CPU or host of host In for carry out network interface card initialization functional module or control chip.
Certainly, host can also be directly after the cpu type for the CPU for determining the host, directly from least two memory blocks In domain, determines the storage region for being stored with driver corresponding with the cpu type of the CPU of host, then load the memory block Driver in the address space in domain, initializes network interface card, and the embodiment of the present invention is without limitation.
It is envisioned that current many hosts may not supported " to match by the reserved field in space register Set the cpu type of the CPU of host " mode indicated to network interface card the host CPU cpu type.For this kind of host, the present invention Embodiment can be by way of being arranged status switch on network interface card, and the current state switched by network interface card detecting state determines master The cpu type of the CPU of machine.
In second of application scenarios of the embodiment of the present invention, status switch is provided on network interface card.Operator can be When installing network interface card for host, according to the cpu type of the CPU of host, the status switch being arranged on network interface card is in corresponding state.Such as This, the current state that network interface card can be switched by detecting state determines the cpu type of the CPU of host.
Specifically, in second of application scenarios of the embodiment of the present invention, as shown in figure 4, the S201 in Fig. 2 can be replaced For S201c-S201d:
The current state of S201c, network interface card detecting state switch.
S201d, network interface card are according to the CPU class of the current state of status switch and the state of status switch and the CPU of host Corresponding relationship between type determines the cpu type of the CPU of host.
In inventive embodiments, the different conditions for the status switch being arranged on network interface card can serve to indicate that different CPU classes Type.Assuming that status switch on network interface card can there are two types of state (first state and the second states), and two are integrated on the network interface card A on-demand memory stores the corresponding driving journey for initializing the network interface card of first kind CPU in two on-demand memories respectively Sequence and the corresponding driver for initializing the network interface card of the second class CPU;When status switch is in first state (such as open state) When, then it can indicate that the CPU of host is first kind CPU, it, then can be with when status switch is in the second state (such as closed state) Indicate that the CPU of host is the second class CPU.
Illustratively, the status switch in the embodiment of the present invention can be wire jumper.For example, the wire jumper can be to be connected to net The metal contact wires of printed circuit board (English: Printed Circuit Board, abbreviation: PCB) two demand points of card.
By this programme, even host is not supported " to configure the CPU of the CPU of host by the reserved field in register The mode of type " indicates the cpu type of the CPU of the host to network interface card, can also pass through the side of the setting status switch on network interface card Formula, the current state switched by network interface card detecting state determine the cpu type of the CPU of host.
Illustratively, at least two storage regions in the embodiment of the present invention are at least two storages being integrated on network interface card Chip;Alternatively, at least two sections of memory spaces, storage chip that at least two storage regions are same storage chip are integrated in network interface card On.At least two storage regions i.e. in the embodiment of the present invention can be at least two different storage chips, be also possible to same Two sections of memory spaces of one storage chip.The embodiment of the present invention does not do the above-mentioned specific physical aspect of at least two storage regions Limitation.
The method of initialization network interface card provided in an embodiment of the present invention, can be in each storage at least two storage regions The driver of initialization network interface card corresponding with one kind CPU, and the driving stored in each storage region are stored in region Program corresponds to different types of CPU, in this way, network interface card can adapt to the host of different types of CPU.Wherein, network interface card can With empty after the cpu type for the CPU for determining host, then by the address of storage region corresponding with the cpu type of the CPU of the host Between be mapped to host.In this way, host can then load the driving in the address space for adapting to the cpu type of CPU of the host Program.It can be seen that the host that the network interface card in this programme can adapt to different types of CPU executes PXE starting, i.e., network interface card can To use PXE function on the host of different cpu types, the host of different cpu types is allowed to use PXE function to this Network interface card is initialized.
Also, no matter whether host supports " cpu type of the CPU of host is configured by the reserved field in register " Mode indicates the cpu type of the CPU of the host to network interface card, and by this programme, network interface card can determine the CPU of the CPU of host Type, then by the Address space mappinD of storage region corresponding with the cpu type of the CPU of host to host, so that host can The driver in address space to load the cpu type for the CPU for adapting to the host, and the network interface card is initialized.
The above-mentioned angle mainly interacted from network interface card with host is described scheme provided in an embodiment of the present invention.It can be with Understand, in order to realize the above functions, it comprises execute the corresponding hardware configuration of each function and/or soft for network interface card and host Part module.Those skilled in the art should be readily appreciated that, described in conjunction with the examples disclosed in the embodiments of the present disclosure Network interface card, host and algorithm steps, the present invention can be realized with the combining form of hardware or hardware and computer software.Some function It can be executed in a manner of hardware or computer software driving hardware actually, the specific application and design depending on technical solution Constraint condition.Professional technician can use different methods to achieve the described function each specific application, but It is that such implementation should not be considered as beyond the scope of the present invention.
The embodiment of the present invention can carry out functional module or functional unit to network interface card and host according to above method example Division, for example, each functional module of each function division or functional unit can be corresponded to, can also by two or two with On function be integrated in a processing module.Above-mentioned integrated module both can take the form of hardware realization, can also adopt It is realized with the form of software function module or functional unit.It should be noted that module or list in the embodiment of the present invention The division of member is schematically that only a kind of logical function partition, there may be another division manner in actual implementation.
Fig. 5 shows a kind of possible structural schematic diagram of network interface card involved in above-described embodiment.At least two storages The driver of initialization network interface card corresponding with one kind CPU, each storage are stored in each storage region in region The driver stored in region corresponds to different types of CPU.The network interface card 50 comprises determining that module 51 and mapping block 52.
Wherein it is determined that module 51, for the determining cpu type with the CPU of the host of network card binding;From at least two storages In region, the storage region for being stored with driver corresponding with the cpu type of the CPU of the host is determined.For example, determining mould Block 51 can be used for supporting the S201 and S202 as in Fig. 2, and/or other processes for techniques described herein.
The Address space mappinD of mapping block 52, the storage region for determining determining module 51 gives the host, with So that host is loaded the driver in corresponding address space, network interface card is initialized.For example, mapping block 52 can be used for It supports such as the S203 in Fig. 2-4 either figure, and/or other processes for techniques described herein.
Corresponding implementation as shown in Figure 3, above-mentioned determining module 51 specifically can be used for: from the register read of network interface card Reserved field, reserved field are used to indicate the cpu type of the CPU of host;Determine the CPU's of host according to the reserved field of reading Cpu type.In the implementation, determining module 51 can be used for supporting S201a, S201b and S202 in Fig. 3.
Implementation as shown in Figure 4 is corresponded to, stateful switch can be set on above-mentioned network interface card.Above-mentioned determining module 51, Be specifically used for: the current state of detecting state switch, and according to the current state of status switch and the state of status switch with Corresponding relationship between the cpu type of the CPU of host determines the cpu type of the CPU of host.In the implementation, determining module 51 can be used for supporting S201c, S201d and S202 in Fig. 4.
Further, as shown in fig. 6, above-mentioned network interface card can also include memory module 53, which includes at least Two storage regions.Alternatively, host has at least two storage regions.
Wherein, at least two storage regions are at least two storage chips being integrated on network interface card;Alternatively, at least two deposit Storage area domain is that at least two sections of memory spaces, the storage chip of same storage chip are integrated on the network interface card.
Using integrated unit, above-mentioned determining module 51 and mapping block 52 can integrate and handle at one It is realized in module, which can be processor or controller, such as can be CPU, general processor, at digital signal Manage device (English: Digital Signal Processor, abbreviation: DSP), specific integrated circuit (English: Application- Specific Integrated Circuit, referred to as: ASIC), field programmable gate array (English: Field Programmable Gate Array, referred to as: FPGA) or other programmable logic device, transistor logic, hardware Component or any combination thereof.It, which may be implemented or executes, combines various illustrative logics described in the disclosure of invention Box, module and circuit.The processing module is also possible to realize the combination of computing function, such as includes one or more micro- places Manage device combination, DSP and the combination of microprocessor etc..Memory module 53 can be memory.
When above-mentioned processing module is processor, and memory module 53 is memory, network interface card involved in the embodiment of the present invention It can be network interface card 70 shown in Fig. 7.
As shown in fig.7, the network interface card 70 includes: data-interface 71 and processor 72.
Data-interface 71, for being interacted with host data.Wherein, which can be wireless interface, this is wireless Interface can carry out data communication by network and host CPU.Alternatively, the data-interface 71 can be wireline interface, such as the number It can be PCIE bus interface according to interface 71, which can establish the laggard line number of physical connection with the CPU of host According to communication.Certainly, data-interface 71 or insertion host card slot (such as back panel connector), and in the card slot of host The interface module of pin contact.
Processor 72, the cpu type of the CPU for determining host;From at least two storage regions, determine be stored with The storage region of the corresponding driver of the cpu type of the CPU of host, and the Address space mappinD of determining storage region is given The host initializes network interface card so that host loads the driver in corresponding address space.
Wherein, initialization net corresponding with one kind CPU is stored in each storage region at least two storage regions The driver of card, the driver stored in each storage region correspond to different types of CPU.
Illustratively, in an implementation of the embodiment of the present invention, above-mentioned at least two storage region can integrate In network interface card.Specifically, as shown in fig. 7, the network interface card 70 can also include: memory 73.It include at least two in the memory 73 A storage region is stored with initialization net corresponding with one kind CPU in each storage region 731 at least two storage regions The driver of card, the driver stored in each storage region correspond to different types of CPU.
In another implementation of the embodiment of the present invention, above-mentioned at least two storage region be may include in host In.
It is envisioned that above-mentioned memory 73 can be also used for storage computer executed instructions.For example, above-mentioned memory It can store network interface card firmware in 73, include above-mentioned computer executed instructions in the network interface card firmware.Processor 72 and memory 73, number It is connected according to interface 72 by bus 74 as shown in Figure 7, when network interface card operation, which executes the meter that memory 73 stores Calculation machine executes instruction, so that network interface card executes the method for initializing network interface card as shown in either figure in Fig. 2-Fig. 4.
Above-mentioned processor 72 may be CPU or specific integrated circuit ASIC, or be arranged to implement this One or more integrated circuits of inventive embodiments.Certainly, processor 72 can also may be used also for fpga chip or processor 72 Think the microprocessor (English: Microprocessor without interlocked piped of no inner interlocked pipelining-stage Stages, referred to as: MIPS) or processor 72 can also for (English: Advanced RISC Machines, referred to as: ARM) Processor, the embodiment of the present invention to this with no restriction.
Wherein, it is total to can be industry standard architecture (Industry Standard Architecture, ISA) for bus Line, external equipment interconnection (Peripheral Component Interconnect, PCI) bus or extension Industry Standard Architecture Structure (Extended Industry Standard Architecture, EISA) bus etc..It is total that the bus can be divided into address Line, data/address bus, control bus etc..Only to be indicated with a thick line in Fig. 7 convenient for indicating, it is not intended that only one total Line or a type of bus.
In a kind of application scenarios, stateful switch can be set on above-mentioned network interface card.Processor 72 specifically can be used for examining The current state of status switch is surveyed, and according to the CPU's of the current state of status switch and the state of status switch and host Corresponding relationship between cpu type determines the cpu type of the CPU of host.
In another application scenarios, above-mentioned processor 72, specifically for the register read reserved field from network interface card, in advance Section of writeeing down characters is used to indicate the cpu type of the CPU of host;The cpu type of the CPU of host is determined according to the reserved field of reading.
Illustratively, the register of above-mentioned network interface card can be the PCIE configuration space registers of network interface card, above-mentioned reserved field The cpu type for being used to indicate the CPU of host is specifically as follows at least one byte or at least one bit in reserved field It is used to indicate the cpu type of the CPU of host.
Further, above-mentioned at least two storage region is at least two storage chips being integrated on network interface card;Alternatively, extremely Few two storage regions are that at least two sections of memory spaces, the storage chip of same storage chip are integrated on network interface card.
The embodiment of the present invention also provides a kind of computer readable storage medium, is stored in the computer readable storage medium One or more programs, the one or more program include instruction, and when the processor 72 of network interface card executes described instruction, network interface card is held The method that row initializes network interface card as shown in either figure in Fig. 2-Fig. 4.
The computer readable storage medium may include high speed RAM memory, it is also possible to further include non-volatile memories Device (non-volatile memory), for example, at least a magnetic disk storage.
It should be noted that each functional unit or the detailed of functional module are retouched in network interface card provided in an embodiment of the present invention It states and each functional unit or functional module is executed as brought by after the correlation technique step in Fig. 2-4 in either figure Technical effect can be with reference to the associated description in embodiment of the present invention method, and details are not described herein again.
Fig. 8 shows a kind of possible structural schematic diagram of host involved in above-described embodiment.At least two storages The driver of initialization network interface card corresponding with a kind of central processor CPU is stored in each storage region in region, often The driver stored in a storage region corresponds to different types of CPU.The host 80 includes: link block 81, write-in mould Block 82 and initialization module 83.
Link block 81 is stored with and one for binding network interface card in each storage region at least two storage regions The driver of the corresponding initialization network interface card of class CPU, the driver stored in each storage region corresponds to different types of CPU。
Host is written in writing module 82, the reserved field for the register in the network interface card bound with link block 81 The cpu type of CPU, so as to network interface card by the Address space mappinD of the corresponding storage region of the cpu type of the CPU of host to host. For example, writing module 82 can be used for supporting the S202 ' as in Fig. 3, and/or other mistakes for techniques described herein Journey.
Initialization module 83, the driver in address space for reading and loading network interface card mapping, carries out network interface card Initialization.For example, initialization module 83 can be used for supporting the S204 as in Fig. 2-4 in either figure, and/or it is used for this paper institute Other processes of the technology of description.
Further, as shown in figure 9, above-mentioned host can also include memory module 84, which includes at least Two storage regions.Alternatively, at least two storage regions are integrated in network interface card.
Wherein, at least two storage regions are at least two storage chips being integrated on network interface card;Alternatively, at least two deposit Storage area domain is that at least two sections of memory spaces, the storage chip of same storage chip are integrated on the network interface card.
Using integrated unit, above-mentioned writing module 82 and initialization module 83 be can integrate at one It is realized in reason module, which can be processor or controller, such as can be CPU, general processor, DSP, ASIC, FPGA or other programmable logic device, transistor logic, hardware component or any combination thereof.It can be with It realizes or executes and combine various illustrative logic blocks, module and circuit described in the disclosure of invention.The processing Module is also possible to realize the combination of computing function, such as combines comprising one or more microprocessors, DSP and microprocessor Combination etc..Memory module 83 can be memory.
When above-mentioned processing module is processor, and memory module 83 is memory, network interface card involved in the embodiment of the present invention It can be network interface card 100 shown in Fig. 10.As shown in Figure 10, which includes: at network interface card connector 101 and one or more Manage device 102.
Network interface card connector 101, for binding network interface card.Be stored in each storage region at least two storage regions with The driver of the corresponding initialization network interface card of a kind of CPU, the driver stored in each storage region correspond to different type CPU.
Processor 102 carries out data interaction by network interface card connector 101 and network interface card, in the net that network interface card connector 101 is bound The cpu type of the CPU of the reserved field write-in host of the register of card, so that network interface card is corresponding by the cpu type of the CPU of host The Address space mappinD of storage region is to host;The driver in the address space of network interface card mapping is read and loads, to network interface card It is initialized.
Illustratively, the network interface card connector 101 in the embodiment of the present invention can be to connect for the data-interface with network interface card Radio interface module.Certainly, network interface card connector 101 may be to connect wireline interface mould for the data-interface with network interface card Block, the network interface card connector 101 can bind network interface card by way of physical connection, and specific network interface card connector 101 can be with net The data-interface of card carries out physical connection.As the network interface card connector 101 in the embodiment of the present invention can be for for installing network interface card Card slot, network interface card can be inserted in the card slot of host.Network interface card connector (card slot) provided in an embodiment of the present invention is specifically as follows master The back panel connector of machine, i.e. network interface card in the embodiment of the present invention can be inserted in back panel connector.
It is envisioned that above-mentioned host 100 can also include the memory 103 for storing computer executed instructions. Processor 102 is connect with memory 103, network interface card connector 101 by bus 104 as shown in Figure 10, should when host operation Processor 102 executes the computer executed instructions that memory 103 stores, so that host is executed such as either figure institute in Fig. 2-Fig. 4 The method of the initialization network interface card shown.
The processor 102 may be a CPU or ASIC, or be arranged to implement the embodiment of the present invention One or more integrated circuits.The processor 102 can run the storage that BIOS or UEFI load network interface card when executing PXE Driver in space (or memory space of host) realizes the initialization of network interface card by PXE.Wherein, bus 104 can be with It is isa bus, pci bus or eisa bus etc..The bus can be divided into address bus, data/address bus, control bus etc..For just It is only indicated with a thick line in expression, Figure 10, it is not intended that an only bus or a type of bus.
The embodiment of the present invention also provides a kind of computer readable storage medium, is stored in the computer readable storage medium One or more programs, the one or more program include instruction, when the processor 102 of network interface card executes described instruction, host Execute the method that network interface card is initialized as shown in either figure in Fig. 2-Fig. 4.The computer readable storage medium may include High speed RAM memory, it is also possible to it further include non-volatile memory, a for example, at least magnetic disk storage.
It should be noted that each functional unit or the detailed of functional module are retouched in host provided in an embodiment of the present invention It states and each functional unit or functional module is executed as brought by after the correlation technique step in Fig. 2-4 in either figure Technical effect can be with reference to the associated description in embodiment of the present invention method, and details are not described herein again.
Through the above description of the embodiments, it is apparent to those skilled in the art that, for description It is convenienct and succinct, only the example of the division of the above functional modules, in practical application, can according to need and will be upper It states function distribution to be completed by different functional modules, i.e., the internal structure of device is divided into different functional modules, to complete All or part of function described above.The specific work process of the system, apparatus, and unit of foregoing description, before can referring to The corresponding process in embodiment of the method is stated, details are not described herein.
In several embodiments provided herein, it should be understood that disclosed system, device and method can be with It realizes by another way.For example, the apparatus embodiments described above are merely exemplary, for example, the module or The division of unit, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units Or component can be combined or can be integrated into another system, or some features can be ignored or not executed.Another point, institute Display or the mutual coupling, direct-coupling or communication connection discussed can be through some interfaces, device or unit Indirect coupling or communication connection can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme 's.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit It is that each unit physically exists alone, can also be integrated in one unit with two or more units.Above-mentioned integrated list Member both can take the form of hardware realization, can also realize in the form of software functional units.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product When, it can store in a computer readable storage medium.Based on this understanding, technical solution of the present invention is substantially The all or part of the part that contributes to existing technology or the technical solution can be in the form of software products in other words It embodies, which is stored in a storage medium, including some instructions are used so that a computer It is each that equipment (can be personal computer, server or the network equipment etc.) or processor (processor) execute the present invention The all or part of the steps of embodiment the method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic or disk Etc. the various media that can store program code.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain Lid is within protection scope of the present invention.Therefore, protection scope of the present invention should be based on the protection scope of the described claims.

Claims (14)

1. a kind of method for initializing network interface card, which is characterized in that stored in each storage region at least two storage regions There are the driver of initialization network interface card corresponding with a kind of central processor CPU, the driving stored in each storage region Program corresponds to different types of CPU, which comprises
The determining cpu type with the CPU of the host of the network card binding;
From at least two storage region, determination is stored with driver corresponding with the cpu type of the CPU of the host Storage region, and by the Address space mappinD of determining storage region give the host so that the host load it is corresponding Driver in address space initializes the network interface card.
2. the method according to claim 1, wherein being provided with status switch on the network interface card;
The cpu type of the CPU of the host of the determination and the network card binding, comprising:
The current state of the status switch is detected, and according to the current state of the status switch and the status switch State and host CPU cpu type between corresponding relationship, determine the cpu type of the CPU of the host.
3. the method according to claim 1, wherein the determination is with the CPU's of the host of the network card binding Cpu type, comprising:
From the register read reserved field of the network interface card, the reserved field is used to indicate the CPU class of the CPU of the host Type;
The cpu type of the CPU of the host is determined according to the reserved field of reading.
4. method according to claim 1-3, which is characterized in that
At least two storage region is at least two storage chips being integrated on the network interface card;Alternatively, described at least two A storage region is that at least two sections of memory spaces, the storage chip of same storage chip are integrated on the network interface card.
5. method according to claim 1-3, which is characterized in that the network interface card and/or the host have institute State at least two storage regions.
6. according to the method described in claim 4, it is characterized in that, the network interface card and/or the host have described at least two A storage region.
7. a kind of method for initializing network interface card, which is characterized in that stored in each storage region at least two storage regions There are the driver of initialization network interface card corresponding with a kind of central processor CPU, the driving stored in each storage region Program corresponds to different types of CPU;The described method includes:
The cpu type of the CPU of the host is written in reserved field of the host in the register of the network interface card, so as to the network interface card Give the Address space mappinD of the corresponding storage region of the cpu type of the CPU of the host to the host;
The host reads and loads the driver that the network interface card is mapped in the address space of the host, to the network interface card It is initialized.
8. a kind of network interface card characterized by comprising data-interface and processor;
The data-interface, for being interacted with host data;
The processor, the cpu type of the central processor CPU for determining the host;From at least two storage regions, It determines and is stored with the storage region of driver corresponding with the cpu type of the CPU of the host, and by determining storage region Address space mappinD give the host so that the host loads the driver in corresponding address space, to the net Card is initialized;Wherein, it is stored in each storage region at least two storage region corresponding with one kind CPU The driver of the network interface card is initialized, the driver stored in each storage region corresponds to different types of CPU.
9. network interface card according to claim 8, which is characterized in that be provided with status switch on the network interface card;
The processor, specifically for detecting the current state of the status switch, and according to the current shape of the status switch Corresponding relationship between the cpu type of the CPU of the state and host of state and the status switch, determines the CPU of the host Cpu type.
10. network interface card according to claim 8, which is characterized in that
The processor, specifically for the register read reserved field from the network interface card, the reserved field is used to indicate institute State the cpu type of the CPU of host;The cpu type of the CPU of the host is determined according to the reserved field of reading.
11. according to the described in any item network interface cards of claim 8-10, which is characterized in that the network interface card includes described at least two depositing Storage area domain.
12. according to the described in any item network interface cards of claim 8-10, which is characterized in that at least two storage region is integrated At least two storage chips on the network interface card;Alternatively, at least two storage region be same storage chip at least Two sections of memory spaces, the storage chip are integrated on the network interface card.
13. network interface card according to claim 11, which is characterized in that at least two storage region is to be integrated in the net At least two storage chips on card;Alternatively, at least two storage region is at least two sections storages of same storage chip Space, the storage chip are integrated on the network interface card.
14. a kind of host characterized by comprising
Network interface card connector, for binding network interface card, the network interface card includes at least two storage regions, at least two storage region In each storage region in be stored with the driver of initialization network interface card corresponding with a kind of central processor CPU, it is described every The driver stored in a storage region corresponds to different types of CPU;
Processor is bound for carrying out data interaction by the network interface card connector and the network interface card in the network interface card connector The network interface card register reserved field be written the host CPU cpu type, so that the network interface card is by the host CPU the corresponding storage region of cpu type Address space mappinD give the host;It reads and loads the network interface card mapping Driver in address space initializes the network interface card.
CN201610648308.6A 2016-08-09 2016-08-09 A kind of method and device initializing network interface card Active CN107729071B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610648308.6A CN107729071B (en) 2016-08-09 2016-08-09 A kind of method and device initializing network interface card

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610648308.6A CN107729071B (en) 2016-08-09 2016-08-09 A kind of method and device initializing network interface card

Publications (2)

Publication Number Publication Date
CN107729071A CN107729071A (en) 2018-02-23
CN107729071B true CN107729071B (en) 2019-10-22

Family

ID=61199316

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610648308.6A Active CN107729071B (en) 2016-08-09 2016-08-09 A kind of method and device initializing network interface card

Country Status (1)

Country Link
CN (1) CN107729071B (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109474475B (en) * 2018-12-07 2020-12-01 天津津航计算技术研究所 Switching system of dual-redundancy network card under windows XPE
CN109728915B (en) * 2018-12-07 2020-12-01 天津津航计算技术研究所 Switching method of dual-redundancy network card under windows XPE
CN110362360A (en) * 2019-07-15 2019-10-22 惠州Tcl移动通信有限公司 Driver loading method, device, mobile terminal and storage medium
CN111835571B (en) * 2020-07-20 2023-04-07 平安科技(深圳)有限公司 Intelligent network card initialization method and device, computer equipment and storage medium
CN113064655B (en) * 2021-04-26 2023-02-28 山东英信计算机技术有限公司 BIOS network starting method and device and computer readable storage medium
CN113204384B (en) * 2021-05-14 2023-05-16 山东英信计算机技术有限公司 Device starting method, device and computer readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101894028A (en) * 2009-05-20 2010-11-24 广州盛华信息技术有限公司 Realization method and device for Linux kernel mirror image data supporting various CPUs
CN102779052A (en) * 2012-06-14 2012-11-14 曙光信息产业(北京)有限公司 Method and system for realizing network card in MIPS (Million Instructions Per Second) framework server
CN102955727A (en) * 2011-08-31 2013-03-06 北京中电华大电子设计有限责任公司 Method for processing firmware simulation model in 802.11n wireless network card

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4275168B2 (en) * 2006-11-30 2009-06-10 シャープ株式会社 System device including NIC and power saving control method of the system device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101894028A (en) * 2009-05-20 2010-11-24 广州盛华信息技术有限公司 Realization method and device for Linux kernel mirror image data supporting various CPUs
CN102955727A (en) * 2011-08-31 2013-03-06 北京中电华大电子设计有限责任公司 Method for processing firmware simulation model in 802.11n wireless network card
CN102779052A (en) * 2012-06-14 2012-11-14 曙光信息产业(北京)有限公司 Method and system for realizing network card in MIPS (Million Instructions Per Second) framework server

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"嵌入式系统网卡驱动模型设计与实现";梅涛 等;《电子科技》;20160415;第29卷(第4期);第111-115页 *

Also Published As

Publication number Publication date
CN107729071A (en) 2018-02-23

Similar Documents

Publication Publication Date Title
CN107729071B (en) A kind of method and device initializing network interface card
CN108008914B (en) The method, apparatus and ARM equipment of disk management in a kind of ARM equipment
US8677097B1 (en) Persistent block storage attached to memory bus
CN102081562A (en) Equipment diagnosis method and system
CN103678053B (en) Computer self-test method and system
CN110515641A (en) The update method of server firmware, apparatus and system
US10866881B1 (en) Firmware debug trace capture
CN109918143A (en) OpenPOWER platform starts information display method and relevant apparatus
CN104156234A (en) Multi-core processor starting and bootloader big-little endian mode adapting method device
CN108694052B (en) Firmware upgrading method, firmware upgrading device and firmware upgrading system
US10067894B1 (en) Cable-based configuration
CN101465754A (en) Method, equipment and communication veneer for loading reset configuration words
US9223697B2 (en) Computer reprogramming method, data storage medium and motor vehicle computer
CN111782474A (en) Log processing method and device, electronic equipment and medium
US20090199216A1 (en) Multi-level driver configuration
CN113204384B (en) Device starting method, device and computer readable storage medium
CN113867743B (en) Network operating system loading and burning method and device, electronic equipment and storage medium
CN115878327A (en) Bus reservation method, device, server, electronic equipment and storage medium
CN109408124A (en) Store equipment and preparation method thereof, operating system double mode bootstrap technique and device
CN102326145B (en) Reset vector code realization method, system and apparatus
US10372661B1 (en) Firmware debug trace capture using serial peripheral interface
JP2005071345A (en) Configurable mapping of device to bus function
US20090138692A1 (en) Self describing line cards in network switch
CN101196821A (en) Motherboard test program initialization system and method thereof
CN114880269B (en) Board ID configuration and identification method, microcontroller and control system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant