From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jerry Van Baren Date: Tue, 16 Dec 2008 08:06:37 -0500 Subject: [U-Boot] [U-Boot-Users] TFTP server support in U-boot In-Reply-To: <4946B31E.10708@gmail.com> References: <19f3dfd10812150059i18a344dam5c25315b3e7f423a@mail.gmail.com> <4946B31E.10708@gmail.com> Message-ID: <4947A7DD.6040909@ge.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Ben Warren wrote: > Hello Santosh, > > santosh pattar wrote: >> Dear All, >> >> As of now in the U-boot only TFTP client is supported. I am planning >> to have TFTP server support in the u-boot. Can you please help me in >> this regarding? >> >> Please provide me few links if this has been done already, or links >> from where i can take some information and start working on it. >> >> > I believe this has come up before, so search the mail archives. I don't > remember anybody posting a patch, though. In general, U-boot doesn't > 'serve', so you have quite a bit of work to do. Luckily, TFTP is one of > the more trivial protocols, hence the name. Do search the archives because my memory isn't what it used to be, but I don't recall a TFTP server coming up. Periodically FTP support comes up and then silently disappears when the requester figures out how much work it would be. Despite sharing 3/4 of the characters and supporting the same concept, TFTP and FTP are totally different animals. > I'm curious why you want to do this. People generally use U-boot as > transient software for loading operating systems that are much more > suitable for serving images. Do you have a situation where you have > several identical devices and want to reduce the upstream network load? > In that case, you may want to look into the multicast TFTP instead. > > regards, > Ben If you really need this, I would suggest adding a simple (modal) "tftp server" command so that, when you execute the command all u-boot is doing is TFTP server work until something indicates "done" (e.g. a file was successfully transfered) and then the command exits. This would fit well into the u-boot restricted architecture that is characterized by being single threaded with no tasking. Trying to do a full fledged tftp server that runs independently in the background is going to be a lot harder because there is no "background" in u-boot. Best regards, gvb