How to obtain a token based on a entity_reference field? I have a node type A with a entity_reference field named "field_subnode" pointing to a node type B:

A -> B

I'm using pathauto, with the following patterns setted up:

URL path for nodes of type A:
books/[node:title]

Now I need something similar to:
books/[node-type-A:title]/[node:title]
as path for my nodes of type B, to obtain urls like the following:

books/my-car-book/chapter-1

Which token I have to use to obtain what I want?

I've tried different tokens like for example:

books/[node:field-subnode:1:title]/[node:title]

but without success.

Thank you for helping me.
You need the Entity Tokens module, part of the Entity project: http://drupal.org/project/entity. Once it's enabled you'll see the available recursive tokens in the tree.