It's a variable.
But the code above might not work. That variable might include the subdir path.
If that is what it does try this:
RewriteRule ^subdirname(.*)$
http://www.rootdomain.com/$1 [R=301,L]
And to explain the caret tells it to look in the request string for the segment that starts after the ^.
Then it looks for a string, use the name of the sub directory.
Then it has a wildcard.
That wildcard is passed on to the $1
So after you do this test the URLs to see what happens, it will probably need to be tweaked till you get it right.