* [U-Boot-Users] DHCP vendor or class ID option
@ 2007-11-06 15:52 Jeffrey Mann
2007-11-06 16:37 ` Ben Warren
0 siblings, 1 reply; 2+ messages in thread
From: Jeffrey Mann @ 2007-11-06 15:52 UTC (permalink / raw)
To: u-boot
U-boot users:
I have been searching the list and reading source code trying to
figure out if something that acomplishes vendor class ids or user
class ids has been implemented in u-boot's dhcp services. (microsoft
has a few articles that discuss uses of class IDS.
http://support.microsoft.com/kb/266675)
What I am trying to acomplish is this: I would like to be able to set
slightly different DHCP options when the DHCP request comes from a
board running u-boot. The point of this is to provide a shorter lease
time (so we don't exceed the size of the address pool when testing
boards) and also to allow different TFTP server addresses to be sent
to these boards.
I see that bp_vend[OPT_SIZE] exists in struct type Bootp_t. Is this a
vendor class id? I see around line 334 in bootp.c this is coppied from
BOOTP_VENDOR_MAGIC. Is setting a vendor class ID as simple as setting
a value for BOOTP_VENDOR_MAGIC in the config file? I cannot find an
example in any other board files.
Thanks,
Jeffrey Mann
^ permalink raw reply [flat|nested] 2+ messages in thread
* [U-Boot-Users] DHCP vendor or class ID option
2007-11-06 15:52 [U-Boot-Users] DHCP vendor or class ID option Jeffrey Mann
@ 2007-11-06 16:37 ` Ben Warren
0 siblings, 0 replies; 2+ messages in thread
From: Ben Warren @ 2007-11-06 16:37 UTC (permalink / raw)
To: u-boot
Hi Jeff,
Jeffrey Mann wrote:
> U-boot users:
>
> I have been searching the list and reading source code trying to
> figure out if something that acomplishes vendor class ids or user
> class ids has been implemented in u-boot's dhcp services. (microsoft
> has a few articles that discuss uses of class IDS.
> http://support.microsoft.com/kb/266675)
>
> What I am trying to acomplish is this: I would like to be able to set
> slightly different DHCP options when the DHCP request comes from a
> board running u-boot. The point of this is to provide a shorter lease
> time (so we don't exceed the size of the address pool when testing
> boards) and also to allow different TFTP server addresses to be sent
> to these boards.
>
> I see that bp_vend[OPT_SIZE] exists in struct type Bootp_t. Is this a
> vendor class id? I see around line 334 in bootp.c this is coppied from
> BOOTP_VENDOR_MAGIC. Is setting a vendor class ID as simple as setting
> a value for BOOTP_VENDOR_MAGIC in the config file? I cannot find an
> example in any other board files.
>
> Thanks,
>
> Jeffrey Mann
>
>
BOOTP_VENDOR_MAGIC is a fixed value (99.130.83.99) as defined in RFC
1048, (and its successor, RFC 1533). You can implement whatever vendor
extensions you want in U-boot. If you want to use vendor extensions, put
this in your board's config header file:
#define CONFIG_BOOTP_VENDOREX
and supply the following two board functions:
u8 *dhcp_vendorex_prep (u8 *e); /* Function for filling in extensions */
u8 *dhcp_vendorex_proc (u8 *e); /* Function for processing the response */
There are a few boards in the tree that use this. Just grep for
CONFIG_BOOTP_VENDOREX
You might want to read this, too, for syntax etc.:
http://www.faqs.org/rfcs/rfc1533.html
Does this make sense?
regards,
Ben
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2007-11-06 16:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-06 15:52 [U-Boot-Users] DHCP vendor or class ID option Jeffrey Mann
2007-11-06 16:37 ` Ben Warren
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox