[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 12/12] xen/iommu: smmu: Add Xen specific code to be able to use the driver
On Tue, 27 Jan 2015, Julien Grall wrote: > On 27/01/15 16:46, Stefano Stabellini wrote: > > On Fri, 16 Jan 2015, Julien Grall wrote: > >> The main goal is to modify as little the Linux code to be able to port > >> easily new feature added in Linux repo for the driver. > > > > Agreed. > > > > > >> To achieve that we: > >> - Add helpers to Linux function not implemented on Xen > > > > Good idea, I would take it further and move the helpers to a separate > > file that smmu.c #includes. Or it could work the other way around: you > > could move the original code to smmu-linux.c that get #included into > > smmu.c > > We would have to modify smmu-linux.c for disabling some functions and/or > modify them. > > Although for the later, there is only a couple functions modified. > > > > >> - Add callbacks used by Xen to do our own stuff and call Linux ones > >> - Only modify when required the code which comes from Linux. If so a > >> comment has been added with /* Xen: ... */ explaining why it's > >> necessary. > > > > I wonder if it makes sense to keep your changes in patch format and > > apply the patch at run time as part of the make system. > > > > Of course you would need to be careful to keep the patched smmu.c > > separate from the original, otherwise it would get very confusing when > > people works on their changes. > > IHMO, it makes more difficult to review and work with it. Although it > may be easier for porting change from Linux in the future. Yes, the reason to do that would be to make it as easy as possible to update it in the future. Ian, do you have an opinion on this? _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |