It doesn't seem to me the code would allow to just use the subpanel's rating or calculated load. This would leave the door open to continuously add multiple subpanels originating from just one main panel. For example, start with a 200amp panel in the house, then add a 150amp subpanel in a garage, then add a 100amp subpanel to the first subpanel to feed a shed, and then add a 60amp subpanel from the shed to feed a hot tub; or is there another code reference to prevent this?
Those who have already responded to your question here are correct.
To add to that: when speaking of the sub-panel rating or the calculated load it must be clear that these are two entirely different issues.
Code actually doesn't allow you just to use the sub-panel ratings; it requires you to use the "calculated load."
The real issue is that "calculated load" is a technical term describing the mathematical result of calculations done according to the NEC directives. A good way to start to learn to find this number would be to get an NEC Handbook and follow the examples given there. The get some MH materials on service sizing/etc. and continue your learning.
As an example of why the rating of a panel and the calculated load are two different animals, take this as an example:
I have a main panel: Rated at 200A. This panel was installed in the house based on requirements for that structure of that size. This does not mean that the panel will ever "see" a 200A load. I could turn on every electrical device at the same time and never total even 80A, even though my house has a 200A panel.
I also have a 100A rated sub-panel supplied from the 200A main above. This panel supplies a pool pump, some backyard lighting, and various power outlets in an attached garage. This panel never sees more than 20A total load. The reason I know this is that the feeders to this panel are #10AWG, and the breaker is a 2P 20A, installed on the cheap by an electrician I know who was unemployed at the time.
The total rating for the panels, in an additive function, is 300A; however, since one is downstream from the other, the 200A main would trip if we ever loaded these things to capacity.
On the other hand, as I have hinted above, I assure you that the "calculated load" for my house isn't more than 125A based on the NEC, and the actual loads are much less than that.