devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* dynamic device tree char driver
@ 2012-08-16 19:43 Alan Tull
       [not found] ` <1345146226-32675-1-git-send-email-atull-EIB2kfCEclfQT0dZR+AlfA@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Alan Tull @ 2012-08-16 19:43 UTC (permalink / raw)
  To: devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ; +Cc: Rob Herring


Hello,

I'm Alan Tull, interested in dynamic features of device trees.

The following patch adds a char driver to add or remove device tree
nodes dynamically.  Its ioctl passes a struct with:
 - size of the blob
 - pointer to the blob

The path to add the nodes under is coded in the blob with dummy nodes.
For example the following can be compiled into a blob and sent to this
driver adding a single node under /soc/apb_periphs:

/dts-v1/;
/ {
        soc {
                apb_periphs {
                        i2c1: i2c@ffc05000 {
                                compatible = "snps,designware-i2c";
                                reg = <0xffc05000 0x1000>;
                                interrupts = <0 159 4>;
                                emptyfifo_hold_master = <1>;
                        };
                };
        };
};

I wanted to get feeback early before I went too far down this particular
path.  As such, this code doesn't do any notification for drivers yet.
Also it won't properly add nested nodes yet.  It can add/remove a single
node and see it show up properly under /proc/device-tree.

Alan Tull
Altera

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-08-21 18:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-16 19:43 dynamic device tree char driver Alan Tull
     [not found] ` <1345146226-32675-1-git-send-email-atull-EIB2kfCEclfQT0dZR+AlfA@public.gmane.org>
2012-08-16 19:43   ` [PATCH 1/1] " Alan Tull
2012-08-18 15:45   ` Rob Herring
     [not found]     ` <502FB8A9.4030907-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-08-21 14:38       ` Alan Tull
2012-08-21 16:51         ` Rob Herring
     [not found]           ` <5033BCAE.6080902-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-08-21 18:55             ` Alan Tull

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).