It's not registration that protects you ... it's use. What makes it a little tricky is that one is a movie and the other is a restaurant. But nevertheless, Ricky Bobby name is part of the Sony Pictures Entertainment "media franchise," which they copyrighted and actually used in 2006. RICK didn't file until 2011; didn't open until 2013.
Registration doesn't protect you against a claim of common-law trademark. Most companies use a trademark attorney to file a registration. Oh look ... RICK prepared their own trademark application with in-house counsel ... figures!