Skip to contentSkip to conversation

Patch: allow a fixed port for TFTP (take 3)

U-Boot-Users Jerry Van Baren 3 participants 11 messages Jan 11, 2005 – Sep 24, 2005

lore
Share & tools
lore
#0 lore raw

Hi Wolfgang, try three on the patch attached. The change here is to rename the env variable per Tolunay Orkun's recommendation.

* Patch by Jerry Van Baren 11 January 2005
- Add a configuration option CONFIG_TFTP_PORT and optional env variable tftpsourceport to force TFTP to use a fixed UDP port.

gvb

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 050111-tftp.patch
Url: http://lists.denx.de/pipermail/u-boot/attachments/20050111/5d3537ef/attachment.txt

#1 lore raw
Quoted 3 lines · In message <[email protected]> you wrote:

Hi Wolfgang, try three on the patch attached. The change here is to rename the env variable per Tolunay Orkun's recommendation.

I reject this because such a long variable name seems unacceptable to me. Don't make life unnecessarily hard to your users. Use a short name. How about "tftpport"?

Best regards,

Wolfgang Denk

Signature · 3 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Artificial Intelligence is no match for natural stupidity.
#2 lore raw

Dear Wolfgang,

Quoted 9 lines · Wolfgang Denk
Quoted 2 lines · In message <[email protected]> you wrote:

Hi Wolfgang, try three on the patch attached. The change here is to rename the env variable per Tolunay Orkun's recommendation.

I reject this because such a long variable name seems unacceptable to me. Don't make life unnecessarily hard to your users. Use a short name. How about "tftpport"?

Wolfgang, "tftpport" is what he has done previously.

It is more appropriate and customary for "tftpport" to refer to the server port (i.e. reference to a port without a qualification of client/server, source/destination etc). This patch on the other hand is leaving the server port as is (well known port) and modifying the normally dynamic source (client) port to a fixed value via environment. I think, using "tftpport" would be a poor choice.

I will pledge for clarity over 6 more bytes in environment which most boards will not define anyway. If that is not reasonable, please allow for "tftpsrcport" or "tftpcport".

I actually want to provide a complimentary patch over this one to make the tftp server port configurable which the environment variable can be appropriately named as one of "tftpserverport", "tftpdestport" or "tftpsport". I also want to use the same CONFIG_TFTP_PORT variable to enable both environment variables unless you object in which case naming the config variables as CONFIG_TFTP_CLIENT_PORT and CONFIG_TFTP_SERVER_PORT is probably better.

Best regards,
Tolunay

#3 lore raw
Quoted 6 lines · In message <[email protected]> you wrote:
Quoted 4 lines

I reject this because such a long variable name seems unacceptable to me. Don't make life unnecessarily hard to your users. Use a short name. How about "tftpport"?

Wolfgang, "tftpport" is what he has done previously.

:-(

Quoted 3 lines

I will pledge for clarity over 6 more bytes in environment which most boards will not define anyway. If that is not reasonable, please allow for "tftpsrcport" or "tftpcport".

So be it "tftpsrcport" then. Or "tftpsrcp" :-)

["tftpcport" ??? TFT-PC-Port? Or 'c' like what???]

Quoted 3 lines

I actually want to provide a complimentary patch over this one to make the tftp server port configurable which the environment variable can be appropriately named as one of "tftpserverport", "tftpdestport" or

tftpdstport or tftpdstp, please.

Quoted 1 line

"tftpsport". I also want to use the same CONFIG_TFTP_PORT variable to

[Seems to be some funny kind of exercise, this: TFTP sport. And is misleading - TFTP _S_ource Port ?]

Quoted 3 lines

enable both environment variables unless you object in which case naming the config variables as CONFIG_TFTP_CLIENT_PORT and CONFIG_TFTP_SERVER_PORT is probably better.

OK.

Best regards,

Wolfgang Denk

Signature · 7 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
They say, well, meybe it _is_ smelly, maybe it _is_ overcrowded, may-
be it _is_ a bit like Hell would be if they shut the  fires  off  and
stabled  a  herd  of  incontinent cows there for a year, but you must
admit that it is full of sheer, vibrant, dynamic _life_.
                                 - Terry Pratchett, _Moving Pictures_
#4 lore raw
Quoted 12 lines · Wolfgang Denk
Quoted 5 lines · In message <[email protected]> you wrote:

I will pledge for clarity over 6 more bytes in environment which most boards will not define anyway. If that is not reasonable, please allow for "tftpsrcport" or "tftpcport".

So be it "tftpsrcport" then. Or "tftpsrcp" :-)

I prefer "tftpsrcport". I hope Jerry will agee as well.

Quoted 3 lines

["tftpcport" ??? TFT-PC-Port? Or 'c' like what???]

'c' was to stand for "client". Just like bootpc and bootps in /etc/services

Quoted 9 lines
Quoted 5 lines

I actually want to provide a complimentary patch over this one to make the tftp server port configurable which the environment variable can be appropriately named as one of "tftpserverport", "tftpdestport" or

tftpdstport or tftpdstp, please.

IMHO, "tftpdstport" is better.

Quoted 8 lines
Quoted 3 lines

"tftpsport". I also want to use the same CONFIG_TFTP_PORT variable to

[Seems to be some funny kind of exercise, this: TFTP sport. And is misleading - TFTP _S_ource Port ?]

Yes, that is kind of vague. Again, I used bootpc and bootps analogy.

Quoted 9 lines
Quoted 5 lines

enable both environment variables unless you object in which case naming the config variables as CONFIG_TFTP_CLIENT_PORT and CONFIG_TFTP_SERVER_PORT is probably better.

OK.

OK for which? OK to use CONFIG_TFTP_PORT for enabling code for both "tftpsrcport" and "tftpdstport"?

Best regards,
Tolunay

#10 lore raw
In reply to Wolfgang Denk
Quoted 6 lines · Wolfgang Denk
Quoted 2 lines · In message <[email protected]> you wrote:

Hi Wolfgang, try three on the patch attached. The change here is to rename the env variable per Tolunay Orkun's recommendation.

Quoted 7 lines

I reject this because such a long variable name seems unacceptable to me. Don't make life unnecessarily hard to your users. Use a short name. How about "tftpport"?

Best regards,

Wolfgang Denk

OK, then I'll stick with my previous patch (Version 2 2005-01-10) which used "tftpport" (that was the only change between v.2 and v.3). I can re-send it to you if you have already trashed my original message.

Thanks,
gvb

#5 lore raw
In reply to Tolunay Orkun
Quoted 48 lines · Tolunay Orkun
Quoted 12 lines · Wolfgang Denk
Quoted 4 lines · In message <[email protected]> you wrote:

I will pledge for clarity over 6 more bytes in environment which most boards will not define anyway. If that is not reasonable, please allow for "tftpsrcport" or "tftpcport".

So be it "tftpsrcport" then. Or "tftpsrcp" :-)

I prefer "tftpsrcport". I hope Jerry will agee as well.

Quoted 3 lines

["tftpcport" ??? TFT-PC-Port? Or 'c' like what???]

'c' was to stand for "client". Just like bootpc and bootps in /etc/services

Quoted 9 lines
Quoted 4 lines

I actually want to provide a complimentary patch over this one to make the tftp server port configurable which the environment variable can be appropriately named as one of "tftpserverport", "tftpdestport" or

tftpdstport or tftpdstp, please.

IMHO, "tftpdstport" is better.

Quoted 7 lines
Quoted 1 line

"tftpsport". I also want to use the same CONFIG_TFTP_PORT variable to

[Seems to be some funny kind of exercise, this: TFTP sport. And is misleading - TFTP _S_ource Port ?]

Yes, that is kind of vague. Again, I used bootpc and bootps analogy.

Quoted 6 lines
Quoted 4 lines

enable both environment variables unless you object in which case naming the config variables as CONFIG_TFTP_CLIENT_PORT and CONFIG_TFTP_SERVER_PORT is probably better.

Quoted 8 lines
Quoted 3 lines

OK.

OK for which? OK to use CONFIG_TFTP_PORT for enabling code for both "tftpsrcport" and "tftpdstport"?

Best regards,
Tolunay

OK, If I follow all the quoting correctly :-O, an acceptable set of names is the following. This is not Tolunay's first choice (sorry), in this case I'll suck up and side with Wolfgang ;-).

tftpsrcp - Source UDP port for TFTP (Jerry's patch) tftpdstp - Destination UDP port for TFTP (Tolunay's projected
follow-on)

Patch Version 4.rc1 to follow...

gvb
"There comes a time in the history of any project when it becomes necessary to shoot the engineers and begin production." (attributed to MacUser in 1990)

#9 lore raw
In reply to Tolunay Orkun
Quoted 9 lines · In message <[email protected]> you wrote:
Quoted 7 lines
Quoted 4 lines

enable both environment variables unless you object in which case naming the config variables as CONFIG_TFTP_CLIENT_PORT and CONFIG_TFTP_SERVER_PORT is probably better.

OK.

OK for which? OK to use CONFIG_TFTP_PORT for enabling code for both "tftpsrcport" and "tftpdstport"?

Yes.

Best regards,

Wolfgang Denk

Signature · 6 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
In any group of employed individuals the only naturally  early  riser
is  _always_  the office manager, who will _always_ leave reproachful
little notes ... on the desks of their subordinates.
                                - Terry Pratchett, _Lords and Ladies_
#6 lore raw
In reply to Jerry Van Baren
Quoted 7 lines · Jerry Van Baren

OK, If I follow all the quoting correctly :-O, an acceptable set of names is the following. This is not Tolunay's first choice (sorry), in this case I'll suck up and side with Wolfgang ;-).

tftpsrcp - Source UDP port for TFTP (Jerry's patch) tftpdstp - Destination UDP port for TFTP (Tolunay's projected
follow-on)

Spelling our "port" fully would make it more readable but I am OK with this. At least we are going to have some consistency between patches.

Per Wolfgang's comments, we are both using CONFIG_TFTP_PORT for your patch and the follow up patch I am going to submit soon.

Quoted 2 lines

Patch Version 4.rc1 to follow...

Thanks for your patience!

#7 lore raw
In reply to Jerry Van Baren
Quoted 10 lines · In message <[email protected]> you wrote:

OK, If I follow all the quoting correctly :-O, an acceptable set of names is the following. This is not Tolunay's first choice (sorry), in this case I'll suck up and side with Wolfgang ;-).

tftpsrcp - Source UDP port for TFTP (Jerry's patch) tftpdstp - Destination UDP port for TFTP (Tolunay's projected
follow-on)

Patch Version 4.rc1 to follow...

You may have notived that I checked in the _porevious_ version of this patch, as the "Patch Version 4.rc1" announced here never made it to the list (or at least not into my stack). Please feel free to submit an incremental patch against the current git.

Best regards,

Wolfgang Denk

Signature · 5 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Programmer's Lament: (Shakespeare, Macbeth, Act I, Scene vii)
        "That we but teach bloody instructions,
        which, being taught, return to plague the inventor..."
#8 lore raw
Quoted 7 lines · In message <[email protected]> I wrote:
Quoted 2 lines

Patch Version 4.rc1 to follow...

You may have notived that I checked in the _porevious_ version of this patch, as the "Patch Version 4.rc1" announced here never made it to the list (or at least not into my stack). Please feel free to submit an incremental patch against the current git.

Please forget this. I just ran over the new version of your patch and added it. Thanks.

Best regards,

Wolfgang Denk

Signature · 5 lines
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Es sind ?berhaupt nur die Dummk?pfe, die sich den Befehlen der  M?ch-
tigen  widersetzen.  Um  sie  zu ruinieren ist es genug, ihre Befehle
treu zu erf?llen.                  - Peter Hacks: "Die sch?ne Helena"