Re: /proc format (was Device Registry (DevReg) Patch 0.2.0)

Tim Jansen (tim@tjansen.de)
Wed, 25 Apr 2001 22:40:49 +0200


On Wednesday 25 April 2001 21:37, you wrote:
> Personally, I think
>> proc_printf(fragment, "%d %d",get_portnum(usbdev), usbdev->maxchild);
> is shorter (and faster) to parse with
> fscanf(input,"%d %d",&usbdev,&maxchild);

Right, but what happens if you need to extend the format? For example
somebody adds support for USB 2.0 to the kernel and you need to some new
values. Then you would have the choice between changing the format and
breaking applications or keeping the format and dont provide the additional
information.
With XML (or single-value-per-file) it is easy to tell application to ignore
unknown tags (or files). When you just list values you will be damned sooner
or later, unless you make up additional rules that say how apps should handle
these cases. And then your approach is no longer simple, but possibly even
more complicated

bye...
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/