Just a guess here, but using the "large dead trunk" version of treeshape will get you something like a 10ft long by 1ft wide log. (Actually, if it's a whole tree, it would likely be a lot thinner than that.) Wood is pretty variable in density, but a (very) rough average for oak is 45lbs per cu.ft.
So that tree trunk weighs around 450lbs, plus or minus. By
falling object rules, that deals 2d6 for first 10ft plus 1d6 per additional 10ft fallen (i think).
I'd allow the target a reflex save to avoid the damage. (Or else roll an attack roll?)
I'd likely just rule that the companion takes the same damage as the target, since the
treeshape spell says hitpoints are unchanged. I suppose it could make the same reflex save, except that in treeshape form, the companion has Dex 0, (so reflex save uses -5 as the Dex modifier rather than the companion's normal modifier).
[edit] I suspect there's a better way to do this involving an attack roll.